[issue14671] isinstance(obj, object) returns True for _old style_ class instances

2012-04-25 Thread Georg Brandl
Georg Brandl added the comment: This is a result of how old-style classes are implemented. If you look at type(Old()), you can see that it isn't Old, but "instance". (And "instance" is a subclass of object again.) "issubclass" for old-style classes doesn't check type(o) but o.__class__, which

[issue14673] add sys.implementation

2012-04-25 Thread Eric Snow
New submission from Eric Snow : (see thread at http://mail.python.org/pipermail/python-ideas/2012-April/014878.html) This is a patch to add sys.implementation to Python (with doc addition). The main motivation is to have an explicit place to look for the name and version of the implementatio

[issue14667] No IDLE

2012-04-25 Thread Brian Curtin
Brian Curtin added the comment: James, since you attached a Windows executable I'll assume that's the platform you're on. Try the following: 1. Open the Start menu 2. Choose "All Programs" (or "Programs" on XP, I think) 3. Scroll to where you see "Python x.y", where you'll see one or more ent

[issue14672] Windows installer: add desktop shortcut(s)

2012-04-25 Thread Jeff Dean
New submission from Jeff Dean : Spun off from Issue3561: I recently saw Brian Curtin's Pycon 2012 presentation. If a goal is to make it easy for new Windows users to run python, consider (optionally) installing a desktop shortcut. This would make it easy for new users to run python (easier

[issue14671] isinstance(obj, object) returns True for _old style_ class instances

2012-04-25 Thread Q
Q added the comment: >>> help(isinstance) isinstance(...) isinstance(object, class-or-type-or-tuple) -> bool Return whether an object is an instance of a class or of a subclass thereof. (...) So are the old-style class instances descendants of the object? I feel like I am mis

[issue14671] isinstance(obj, object) returns True for _old style_ class instances

2012-04-25 Thread Benjamin Peterson
Benjamin Peterson added the comment: Yes, everything is a object. issubclass, though, works differently for old-style and new-style classes. -- nosy: +benjamin.peterson resolution: -> invalid status: open -> closed ___ Python tracker

[issue14671] isinstance(obj, object) returns True for _old style_ class instances

2012-04-25 Thread Q
Q added the comment: In addition: >>> issubclass(Old, object) False -- ___ Python tracker ___ ___ Python-bugs-list mailing list Unsu

[issue14671] isinstance(obj, object) returns True for _old style_ class instances

2012-04-25 Thread Q
Changes by Q : -- title: isinstance(obj, object) returns True for _old style_ classes -> isinstance(obj, object) returns True for _old style_ class instances ___ Python tracker

[issue14671] isinstance(obj, object) returns True for _old style_ classes

2012-04-25 Thread Q
New submission from Q : $python Python 2.6.5 (r265:79063, Apr 16 2010, 13:09:56) [GCC 4.4.3] on linux2 >>> class Old: pass >>> class New(object): pass >>> o = Old() >>> n = New() >>> isinstance(o, object) True This is it, basically. Is it a bug or a feature? More tests : >>> isinstance(o, Old

[issue14443] Distutils test_bdist_rpm failure

2012-04-25 Thread Nick Coghlan
Nick Coghlan added the comment: Antoine (added to nosy list) indicated he wasn't seeing the failure on a Mageia system, so that's another point in favour of a Fedora/RHEL specific problem. Also added Dave Malcolm as the Fedora Python package maintainer. Applying #11599 to get the full failing

[issue13473] Add tests for files byte-compiled by distutils[2]

2012-04-25 Thread Nick Coghlan
Nick Coghlan added the comment: Your basic approach looks sensible to me. One trick I use in test_cmd_line_script to prevent recreation is to simply delete the source file. If the source is gone, implicit recreation is impossible. Unfortunately, that doesn't work for __pycache__, since the ca

[issue14657] Avoid two importlib copies

2012-04-25 Thread Nick Coghlan
Nick Coghlan added the comment: My plan would be for the frozen version to be entirely implicit, and have only the subsequent import of the version from disk actually modify the public hooks. However, I realised today that my current patch would break "stdlib-from-zipfile" approaches, so any

[issue14605] Make import machinery explicit

2012-04-25 Thread Brett Cannon
Brett Cannon added the comment: Just to document why my explicit sys.path_hooks patch didn't quite change the meaning of None in sys.path_importer_cache, I found a bunch of places in the stdlib and in Modules/main.c where NullImporter is explicitly expected to be returned, so I wanted to get

[issue14605] Make import machinery explicit

2012-04-25 Thread Roundup Robot
Roundup Robot added the comment: New changeset 57d558f1904d by Brett Cannon in branch 'default': Issue #14605: Make explicit the entries on sys.path_hooks that used to http://hg.python.org/cpython/rev/57d558f1904d -- ___ Python tracker

[issue6649] idlelib/rpc.py missing exit status on exithook

2012-04-25 Thread Roger Serwy
Changes by Roger Serwy : -- nosy: +terry.reedy ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.pytho

[issue13078] IDLE: Python Crashes When Saving Or Opening

2012-04-25 Thread Roger Serwy
Roger Serwy added the comment: Closing this issue due to lack of feedback. -- resolution: -> works for me status: pending -> closed ___ Python tracker ___ _

[issue9150] IDLE should not save trailing whitespace after strip trailing whitespace has been used

2012-04-25 Thread Roger Serwy
Roger Serwy added the comment: Closing this issue. Strip trailing whitespace works for me. -- resolution: -> works for me status: pending -> closed ___ Python tracker ___ __

[issue14605] Make import machinery explicit

2012-04-25 Thread Roundup Robot
Roundup Robot added the comment: New changeset 8dab93ec19de by Brett Cannon in branch 'default': Issue #14605: Insert to the front of sys.path_hooks instead of appending. http://hg.python.org/cpython/rev/8dab93ec19de -- ___ Python tracker

[issue14670] subprocess.call with pipe character in argument

2012-04-25 Thread R. David Murray
R. David Murray added the comment: Ah, I thought I remembered seeing something about '|' in windows before, and I was right. It is only special to cmd.exe, which means it is only special when shell=True. See issue 1300 for a discussion. -- status: open -> closed ___

[issue14670] subprocess.call with pipe character in argument

2012-04-25 Thread STINNER Victor
Changes by STINNER Victor : -- nosy: +haypo ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.

[issue8304] strftime and Unicode characters

2012-04-25 Thread Brian Curtin
Changes by Brian Curtin : -- nosy: -brian.curtin ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.py

[issue6815] UnicodeDecodeError in os.path.expandvars

2012-04-25 Thread STINNER Victor
Changes by STINNER Victor : -- nosy: +haypo versions: -Python 2.6, Python 2.7, Python 3.2 ___ Python tracker ___ ___ Python-bugs-list

[issue8304] strftime and Unicode characters

2012-04-25 Thread STINNER Victor
STINNER Victor added the comment: > Actually the bug seems related to Windows. See also the issue #10653: wcsftime() doesn't format correctly time zones, so Python 3 uses strftime() instead. -- nosy: +haypo ___ Python tracker

[issue11574] TextIOWrapper: Unicode Fallback Encoding on Python 3.3

2012-04-25 Thread STINNER Victor
STINNER Victor added the comment: I don't think that using a fallback is a good idea. So I'm closing the issue. You can reopen the discussion on the python-dev mailing list if you don't agree with me or Martin. -- resolution: -> wont fix status: open -> closed __

[issue12632] Python 3 doesn't support cp65001 as the OEM code page

2012-04-25 Thread STINNER Victor
STINNER Victor added the comment: > LookupError: unknown encoding: cp65001 The initial issue was solved by the issue #13216. For other issues with the Windows Console, see the issue #1602. -- resolution: -> fixed status: open -> closed ___ Python

[issue1522400] irda socket support

2012-04-25 Thread Charles-François Natali
Charles-François Natali added the comment: Actually I think it suffers from the same problem as AF_UNIX: sockaddr_irda->sir_name, like sockaddr_un->sun_path, don't have to be NUL-terminated, and the kernel can return non NUL-terminated strings. Which means that such code: {

[issue14605] Make import machinery explicit

2012-04-25 Thread Brett Cannon
Brett Cannon added the comment: importlib.find_module() (or get_loader() as it would replace pkgutil.get_loader() as well) is definitely planned. So is importlib.util.resolve_name() (although maybe that is basic enough to want top-level?). -- ___

[issue13266] Add inspect.unwrap(f) to easily unravel "__wrapped__" chains

2012-04-25 Thread Daniel Urban
Daniel Urban added the comment: I've attached a patch implementing inspect.unwrap (+ some tests). -- keywords: +patch Added file: http://bugs.python.org/file25368/inspect_unwrap.patch ___ Python tracker __

[issue14059] Implement multiprocessing.Barrier

2012-04-25 Thread Charles-François Natali
Charles-François Natali added the comment: The patch looks good. However, I've had two failures while testing it: - a BrokenBarrierError on test_default_timeout: I see you've already increased the timeout from the original threading code, but you can probably double it (we have some slow build

[issue14605] Make import machinery explicit

2012-04-25 Thread Eric Snow
Eric Snow added the comment: While not in the initial list, _find_module() would be really handy. Perhaps we could call it "get_loader" instead. "find_module" is a misleading name and I don't see any parallel with imp.find_module as something to aspire to. -- __

[issue1522400] irda socket support

2012-04-25 Thread Gregory P. Smith
Gregory P. Smith added the comment: Your updated patch looks fine to me. I don't see any reason not to commit it and mention it in the release notes. If it has bugs, they can be discovered and fixed later by people with actual relevant hardware an interest. -- nosy: +gregory.p.smith

[issue14642] Fix importlib.h build rule to not depend on hg

2012-04-25 Thread Martin v . Löwis
Martin v. Löwis added the comment: I'm working on a "hg touch" extension which is able to bring the time stamps back in correct order after a checkout. One would either do "make touch" after an update, or register that extension as a post-update action in .hg/hgrc. It will be controlled by a

[issue14579] CVE-2012-2135: Vulnerability in the utf-16 decoder after error handling

2012-04-25 Thread Martin v . Löwis
Changes by Martin v. Löwis : -- title: Vulnerability in the utf-16 decoder after error handling -> CVE-2012-2135: Vulnerability in the utf-16 decoder after error handling ___ Python tracker ___

[issue14670] subprocess.call with pipe character in argument

2012-04-25 Thread R. David Murray
R. David Murray added the comment: Oops, I typed too fast, and didn't notice that you were talking about windows. My point may still be valid, but I shouldn't be the one to close the issue since I don't know for sure for windows. -- ___ Python tra

[issue14670] subprocess.call with pipe character in argument

2012-04-25 Thread R. David Murray
Changes by R. David Murray : -- Removed message: http://bugs.python.org/msg159330 ___ Python tracker ___ ___ Python-bugs-list mailing

[issue14670] subprocess.call with pipe character in argument

2012-04-25 Thread R. David Murray
R. David Murray added the comment: Oops, I typed too fact, and didn't notice that you were talking about windows. My point may still be valid, but I shouldn't be the one to close the issue since I don't know for sure for windows. -- nosy: +brian.curtin status: closed -> open ___

[issue14670] subprocess.call with pipe character in argument

2012-04-25 Thread R. David Murray
R. David Murray added the comment: If shell is false, the pipe character is not special. -- nosy: +r.david.murray resolution: -> invalid stage: -> committed/rejected status: open -> closed ___ Python tracker ___

[issue14657] Avoid two importlib copies

2012-04-25 Thread Marc-Andre Lemburg
Marc-Andre Lemburg added the comment: Marc-Andre Lemburg wrote: > > Marc-Andre Lemburg added the comment: > > Nick Coghlan wrote: >> >> Nick Coghlan added the comment: >> >> At the very least, failing to regenerate importlib.h shouldn't be a fatal >> build error. It should just run with wha

[issue14605] Make import machinery explicit

2012-04-25 Thread Roundup Robot
Roundup Robot added the comment: New changeset 5fea362b92fc by Marc-Andre Lemburg in branch 'default': Issue #14605 and #14642: Issue a warning in case Python\importlib.h needs to http://hg.python.org/cpython/rev/5fea362b92fc -- ___ Python tracker <

[issue14642] Fix importlib.h build rule to not depend on hg

2012-04-25 Thread Roundup Robot
Roundup Robot added the comment: New changeset 5fea362b92fc by Marc-Andre Lemburg in branch 'default': Issue #14605 and #14642: Issue a warning in case Python\importlib.h needs to http://hg.python.org/cpython/rev/5fea362b92fc -- ___ Python tracker <

[issue14579] Vulnerability in the utf-16 decoder after error handling

2012-04-25 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: I thought it was one error, and not two. The updated patch adds tests and fixes minor mistake. 2.7 is not affected by main security issue, but it contains one of mentioned bugs (read 1 byte outside of the input array). A patch for 2.7 fixes this bug and also

[issue13789] _tkinter does not build on Windows 7

2012-04-25 Thread Steven Winfield
Steven Winfield added the comment: The tk sources (at least the 8.5.11 version I'm looking at now) have some X11 headers that can be used by the windows build in the "xlib" directory. -- nosy: +steven.winfield ___ Python tracker

[issue14670] subprocess.call with pipe character in argument

2012-04-25 Thread Pedro Larroy
New submission from Pedro Larroy : When running a command with pipe character as argument the result is not the same as in commandline For example: >>> subprocess.call([r"C:\Program Files (x86)\Microsoft Visual Studio 10.0\Commo n7\IDE\devenv","/build",r"Debug|x64","gpc10.sln"], shell=False)

[issue14666] test_sendall_interrupted hangs on FreeBSD with a zombi multiprocessing thread

2012-04-25 Thread Antoine Pitrou
Antoine Pitrou added the comment: > For the new method: it may be nice to document it. Having to import > resource_sharer from multiprocessing.reduction is maybe not the best > possible API :-/ resource_sharer is a private API, it's not meant to be used by anyone outside of the stdlib. > What

[issue14666] test_sendall_interrupted hangs on FreeBSD with a zombi multiprocessing thread

2012-04-25 Thread STINNER Victor
STINNER Victor added the comment: mp_resource_sharer_stop.patch: you should add a timeout argument to stop() instead of hardcoding a timeout of 5 seconds. It is maybe safer to block until the thread exits by default (so timeout=None by default). For the new method: it may be nice to document

[issue14579] Vulnerability in the utf-16 decoder after error handling

2012-04-25 Thread Henri Salo
Henri Salo added the comment: I tested versions 3.1.1, 3.1.2, 3.1.3, 3.1.4 and 3.1.5 and only 3.1.3 crashed with Segmentation fault: Program received signal SIGSEGV, Segmentation fault. 0x004c483a in PyObject_Call (func=0x77e4d3b0, arg=0x770fd410, kw=0x0) at Objects/abstract.c

[issue11599] Useless error message when distutils fails compiling

2012-04-25 Thread Éric Araujo
Éric Araujo added the comment: I will apply this this week; I don’t think I need to ask the ML after all, the output is already different when you run with DISTUTILS_DEBUG — and it’s debug mode anyway, not regular use, so I don’t foresee any compat issue. -- versions: -Python 3.1 __

[issue14579] Vulnerability in the utf-16 decoder after error handling

2012-04-25 Thread Antoine Pitrou
Changes by Antoine Pitrou : -- nosy: +benjamin.peterson ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe: http://

[issue14657] Avoid two importlib copies

2012-04-25 Thread Marc-Andre Lemburg
Marc-Andre Lemburg added the comment: Nick Coghlan wrote: > > Nick Coghlan added the comment: > > At the very least, failing to regenerate importlib.h shouldn't be a fatal > build error. It should just run with what its got, and hopefully you will get > a working interpreter out the other e

[issue14579] Vulnerability in the utf-16 decoder after error handling

2012-04-25 Thread Henri Salo
Henri Salo added the comment: Debian bug-report: http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=670389 Found in versions python3-defaults/3.2.3~rc1-2, python3-defaults/3.1.3-12+squeeze1 -- nosy: +Henri.Salo ___ Python tracker

[issue14657] Avoid two importlib copies

2012-04-25 Thread Brett Cannon
Brett Cannon added the comment: So how would you tweak the explicit work I'm doing? The code is going to rely on sys.path_hooks and sys.meta_path being populated. I guess the frozen code can set up initially, and then importlib simply substitutes out classes from the frozen module to the code

[issue14642] Fix importlib.h build rule to not depend on hg

2012-04-25 Thread Brett Cannon
Brett Cannon added the comment: When you do a fresh checkout, Python/importlib.h comes after Lib/importlib/_bootstrap.py and Python/freeze_importlib.py in a lexicographical sort which leads to it have a newer timestamp and thus not triggering a new build of the file. This is why Martin sugge

[issue11599] Useless error message when distutils fails compiling

2012-04-25 Thread Antoine Pitrou
Antoine Pitrou added the comment: Ping. -- ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.

[issue14443] Distutils test_bdist_rpm failure

2012-04-25 Thread Éric Araujo
Éric Araujo added the comment: > I'm wondering if there may be a deeper problem here: how certain are we that > bdist_rpm isn't using the system Python > to handle the byte compilation step? It would explain why the files are still > being generated in the old locations. I’ve had a quick look

[issue14669] test_multiprocessing failure on OS X Tiger

2012-04-25 Thread Antoine Pitrou
New submission from Antoine Pitrou : The OS X Tiger fails more or less intermittently on one of the new multiprocessing tests: == FAIL: test_pickling (test.test_multiprocessing.WithProcessesTestPicklingConnections) ---

[issue14660] Implement PEP 420: Implicit Namespace Packages

2012-04-25 Thread Éric Araujo
Changes by Éric Araujo : -- nosy: +eric.araujo ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.pyth

[issue14657] Avoid two importlib copies

2012-04-25 Thread Nick Coghlan
Nick Coghlan added the comment: At the very least, failing to regenerate importlib.h shouldn't be a fatal build error. It should just run with what its got, and hopefully you will get a working interpreter out the other end, such that you can regenerate the frozen module on the next pass. If

[issue14657] Avoid two importlib copies

2012-04-25 Thread Nick Coghlan
Nick Coghlan added the comment: The other advantage of splitting the entry points is that we can tweak Brett's plan to make the import machinery explicit such that it happens in a separate function that's only called from __init__.py. That way the published hooks will always be from the on-di

[issue14642] Fix importlib.h build rule to not depend on hg

2012-04-25 Thread Éric Araujo
Éric Araujo added the comment: > The status quo seems to work, but people like Georg think it's partially luck > that > it does and if hg changes its semantics that will cause us trouble. Could you expand on that? -- nosy: +eric.araujo ___ Python t

[issue14657] Avoid two importlib copies

2012-04-25 Thread Antoine Pitrou
Antoine Pitrou added the comment: > Actually, rather than a test in test suite, we would just change the > current automatic rebuild to a Modules/Setup style > "'Lib/importlib._bootstrap.py' is newer than 'Python/importlib.h', you > may need to run 'make freeze_importlib'" -1 from me. Nobody pa

[issue1521950] shlex.split() does not tokenize like the shell

2012-04-25 Thread Vinay Sajip
Changes by Vinay Sajip : Added file: http://bugs.python.org/file25365/9252961a03e7.diff ___ Python tracker ___ ___ Python-bugs-list mailing

[issue14657] Avoid two importlib copies

2012-04-25 Thread Éric Araujo
Éric Araujo added the comment: > How do we currently tell that the interpreter is running in a checkout? sysconfig.is_python_build() Someone has to confirm that this works on Windows too, as I’ve been told that not installed vs. installed is less clear on that OS. -- nosy: +eric.arauj

[issue14668] Document the path option in the Windows installer

2012-04-25 Thread Éric Araujo
Éric Araujo added the comment: Don’t forget Doc/using/windows.rst and maybe the various FAQs too (general FAQ, using FAQ, devguide FAQ). -- nosy: +eric.araujo ___ Python tracker __

[issue3561] Windows installer should add Python and Scripts directories to the PATH environment variable

2012-04-25 Thread Éric Araujo
Éric Araujo added the comment: [Jeff Dean] > If a goal is to make it easy for new users to run python, consider installing > a desktop shortcut. > This would make it very easy for new users (easier than starting up a shell). > This is independent of the Path changes discussed here. Hi Jeff; th

[issue14657] Avoid two importlib copies

2012-04-25 Thread Nick Coghlan
Nick Coghlan added the comment: Actually, rather than a test in test suite, we would just change the current automatic rebuild to a Modules/Setup style "'Lib/importlib._bootstrap.py' is newer than 'Python/importlib.h', you may need to run 'make freeze_importlib'" -- _

[issue14664] Skipping a test mixin gives metaclass error

2012-04-25 Thread Michael Foord
Michael Foord added the comment: Thanks Antoine - much appreciated. -- ___ Python tracker ___ ___ Python-bugs-list mailing list Unsub

[issue14579] Vulnerability in the utf-16 decoder after error handling

2012-04-25 Thread Kurt Seifried
Changes by Kurt Seifried : -- nosy: -kseifr...@redhat.com ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe: http

[issue14657] Avoid two importlib copies

2012-04-25 Thread Nick Coghlan
Nick Coghlan added the comment: Yes, in that you'll be able to pick up changes in _bootstrap.py *without* having to rebuild Python. With this in place, we could then get rid of the automatic regeneration of importlib.h which is a complete nightmare if you ever break your built interpreter wh

[issue14664] Skipping a test mixin gives metaclass error

2012-04-25 Thread Antoine Pitrou
Antoine Pitrou added the comment: > This could go into 2.7 too. Done! -- versions: +Python 2.7 ___ Python tracker ___ ___ Python-bug

[issue14664] Skipping a test mixin gives metaclass error

2012-04-25 Thread Roundup Robot
Roundup Robot added the comment: New changeset 8a8d2f05068a by Antoine Pitrou in branch '2.7': Issue #14664: It is now possible to use @unittest.skip{If,Unless} on a test class that doesn't inherit from TestCase (i.e. a mixin). http://hg.python.org/cpython/rev/8a8d2f05068a --

[issue14657] Avoid two importlib copies

2012-04-25 Thread Antoine Pitrou
Antoine Pitrou added the comment: > Attached patch is an initial attempt (the reference counting on the > two modules is likely still a bit dodgy - this is my first version > that didn't segfault as I got used to the mechanics of dealing with a > frozen module, so it errs on the side of leaking

[issue3561] Windows installer should add Python and Scripts directories to the PATH environment variable

2012-04-25 Thread Antoine Pitrou
Antoine Pitrou added the comment: > Unfortunately, from what I can tell, this is OFF by default. I think > that is a mistake. The default for something like this is really > important because without new users being explicitly told to set it, > new users will not. Most new Python users are just

[issue14666] test_sendall_interrupted hangs on FreeBSD with a zombi multiprocessing thread

2012-04-25 Thread Antoine Pitrou
Antoine Pitrou added the comment: > I don't think that you should call pthread_sigmask(). It looks like a > workaround for this issue, whereas resource_sharer.stop() is the > correct fix. The problem is not only with test_multiprocessing and test_socket; any test which uses multiprocessing cou

[issue14657] Avoid two importlib copies

2012-04-25 Thread Nick Coghlan
Nick Coghlan added the comment: OK, I'm leaning back towards my original preference of getting _frozen_importlib out of the way as quickly as we can. Specifically, I'm thinking of separating out the entry point used by importlib.__init__ from that used by pythonrun.c, such that the latter cal

[issue3561] Windows installer should add Python and Scripts directories to the PATH environment variable

2012-04-25 Thread Chris Lambacher
Chris Lambacher added the comment: The reason for the conditional approach was to attempt to account for the "negative consequences" of adding enabling this by default. i.e. if you are already a Python developer and install a new version, it will be status quo, but if you are a new Python dev

[issue14642] Fix importlib.h build rule to not depend on hg

2012-04-25 Thread Brett Cannon
Brett Cannon added the comment: This is where a script could help with printing out a warning if the built Python interpreter is not available. -- ___ Python tracker ___ __

[issue14660] Implement PEP 420: Implicit Namespace Packages

2012-04-25 Thread Brett Cannon
Brett Cannon added the comment: The joys of trying to shoehorn into an existing API. I mean short of adding a new sys.namespace_loader instead of an explicit keyword argument to FileFinder I can't think of a better solution. -- ___ Python tracker

[issue14657] Avoid two importlib copies

2012-04-25 Thread Brett Cannon
Brett Cannon added the comment: To answer MAL's question about startup, I benchmarked on my machine using the normal_startup benchmark from hg.python.org/benchmarks and the bootstrap work only caused a 5-6% slowdown in a non-debug build. If you do it in a debug build it's much worse (I think

[issue14660] Implement PEP 420: Implicit Namespace Packages

2012-04-25 Thread Eric V. Smith
Eric V. Smith added the comment: Ah. I didn't realize that reload called load_module. I'll back out the change I just made, then. My point was that the original call to load_module isn't made through the normal "a finder returned me a loader, so I'll call it" code path. It's always made thro

[issue14660] Implement PEP 420: Implicit Namespace Packages

2012-04-25 Thread Brett Cannon
Brett Cannon added the comment: What do you mean the loader is only needed to set __loader__? You need the loader to create the module (or find it in sys.modules to reload), and set all the attributes properly. If you do this then reloading namespace modules will become a special case compare

[issue3561] Windows installer should add Python and Scripts directories to the PATH environment variable

2012-04-25 Thread Martin v . Löwis
Martin v. Löwis added the comment: lambacck: I'm -1, but I'm willing to yield to anybody who wants to be "in charge" of this feature (i.e. Brian, or the release manager). I'm not willing yield to "mere" user requests, as regular users won't have to deal with negative consequences that enablin

[issue3561] Windows installer should add Python and Scripts directories to the PATH environment variable

2012-04-25 Thread Chris Lambacher
Chris Lambacher added the comment: I am really happy to see this as an option in the Windows installer. This has a potential to really reduce the support burden on training new Windows users to use Python and will really help normalize the experience for new users between Windows and POSIX pl

[issue14369] make __closure__ writable

2012-04-25 Thread Richard Oudkerk
Richard Oudkerk added the comment: Version of patch which checks invariants in the setter and adds tests. -- Added file: http://bugs.python.org/file25363/writable_closure_with_checking.patch ___ Python tracker __

[issue14666] test_sendall_interrupted hangs on FreeBSD with a zombi multiprocessing thread

2012-04-25 Thread STINNER Victor
STINNER Victor added the comment: mp_resource_sharer_stop.patch: this patch changes two different things, the patch should be splitted. One patch to fix test_socket. One patch to call pthread_sigmask(). I don't think that you should call pthread_sigmask(). It looks like a workaround for this is

[issue14664] Skipping a test mixin gives metaclass error

2012-04-25 Thread Michael Foord
Michael Foord added the comment: This could go into 2.7 too. -- ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe:

[issue14666] test_sendall_interrupted hangs on FreeBSD with a zombi multiprocessing thread

2012-04-25 Thread Antoine Pitrou
Antoine Pitrou added the comment: Hmm, I thought either multiprocessing's logging facilities, or the warnings module, could be used. That way, people have a control over verbosity of stderr messages. -- ___ Python tracker

[issue3561] Windows installer should add Python and Scripts directories to the PATH environment variable

2012-04-25 Thread Brian Curtin
Brian Curtin added the comment: Now that the feature is in, I'm going to track the few places we need to document it in #14668. -- resolution: -> fixed stage: commit review -> committed/rejected status: open -> closed ___ Python tracker

[issue12488] multiprocessing.Connection does not communicate pipe closure between parent and child

2012-04-25 Thread Sye van der Veen
Sye van der Veen added the comment: This issue _does_ exist on Windows, and is not limited to the case where the master process exits before its children. The following code, which is almost exactly that from the 2.7.3 documentation, deadlocks on Win7 (Py3.2 and 2.7) and WinXP (Py3.2 and 2.6

[issue14668] Document the path option in the Windows installer

2012-04-25 Thread Brian Curtin
New submission from Brian Curtin : Now that #3561 is in, it needs to be mentioned in at least the following places: Doc\whatsnew\3.3.rst Doc\faq\windows.rst http://python.org/download/windows/ could use an update, but that's on a separate SVN repository -- assignee: brian.curtin compon

[issue3561] Windows installer should add Python and Scripts directories to the PATH environment variable

2012-04-25 Thread Roundup Robot
Roundup Robot added the comment: New changeset 4e9f1017355f by Brian Curtin in branch 'default': Fix #3561. Add an option to place the Python installation into the Windows Path environment variable. http://hg.python.org/cpython/rev/4e9f1017355f -- nosy: +python-dev ___

[issue14666] test_sendall_interrupted hangs on FreeBSD with a zombi multiprocessing thread

2012-04-25 Thread Richard Oudkerk
Richard Oudkerk added the comment: Warning added to patch. -- Added file: http://bugs.python.org/file25362/mp_resource_sharer_stop.patch ___ Python tracker ___ _

[issue14664] Skipping a test mixin gives metaclass error

2012-04-25 Thread Antoine Pitrou
Antoine Pitrou added the comment: Fixed, thanks. -- resolution: -> fixed stage: patch review -> committed/rejected status: open -> closed ___ Python tracker ___ ___

[issue14664] Skipping a test mixin gives metaclass error

2012-04-25 Thread Roundup Robot
Roundup Robot added the comment: New changeset ab3df6979bd0 by Antoine Pitrou in branch '3.2': Issue #14664: It is now possible to use @unittest.skip{If,Unless} on a test class that doesn't inherit from TestCase (i.e. a mixin). http://hg.python.org/cpython/rev/ab3df6979bd0 New changeset 188b96

[issue14660] Implement PEP 420: Implicit Namespace Packages

2012-04-25 Thread Yury Selivanov
Changes by Yury Selivanov : -- nosy: +Yury.Selivanov ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe: http://mai

[issue14660] Implement PEP 420: Implicit Namespace Packages

2012-04-25 Thread Eric V. Smith
Eric V. Smith added the comment: I'd really prefer something like: return load_ns_module(fullname, namespace_path) The point being that load_module() as defined in PEP 302 will never be called on NamespaceLoader. The loader only needs to exist to set module.__loader__, and load_module() wo

[issue14657] Avoid two importlib copies

2012-04-25 Thread Antoine Pitrou
Antoine Pitrou added the comment: > Looking at Antoine's patch, I'd be happier with it if it *didn't* > mutate the attributes of _frozen_importlib, but instead just added > importlib._bootstrap as an alias for accessing it. I thought it would be nicer for __file__, __name__ and __package__ to r

[issue14657] Avoid two importlib copies

2012-04-25 Thread Antoine Pitrou
Antoine Pitrou added the comment: > Would be easier to tell distutils to install the extensions > in a fixed name dir (instead of using a platform and version > in the name) and then use that getpath.c. distutils is pretty > flexible at that :-) Look, this is becoming very off-topic and you are

[issue14657] Avoid two importlib copies

2012-04-25 Thread Nick Coghlan
Nick Coghlan added the comment: Still no patch from me, but I did create the rudiments of a shared script for poking around at the import internals (Tools/scripts/import_diagnostics.py) Looking at Antoine's patch, I'd be happier with it if it *didn't* mutate the attributes of _frozen_importli

[issue14657] Avoid two importlib copies

2012-04-25 Thread Marc-Andre Lemburg
Marc-Andre Lemburg added the comment: Antoine Pitrou wrote: > > Antoine Pitrou added the comment: > >> The question pybuildir.txt apparently tries to solve is whether Python >> is running from the build dir or not. It's not whether Python was >> installed or not. > > That's the same, for all

[issue14666] test_sendall_interrupted hangs on FreeBSD with a zombi multiprocessing thread

2012-04-25 Thread Antoine Pitrou
Antoine Pitrou added the comment: > in the thread (is that right?). This looks like it. > It also uses a timeout when trying to join the thread. Perhaps some kind of warning can be printed if joining fails after the timeout? -- ___ Python tracker

  1   2   >