[issue6699] IDLE: Warn user about overwriting a file that has a newer version on filesystem

2013-05-08 Thread Terry J. Reedy
Changes by Terry J. Reedy : -- versions: +Python 2.7, Python 3.4 -Python 3.2 ___ Python tracker ___ ___ Python-bugs-list mailing list U

[issue2704] IDLE: Patch to make PyShell behave more like a Terminal interface

2013-05-08 Thread Roger Serwy
Roger Serwy added the comment: Welcome Phil! Your patch looks good and applied cleanly to the default branch and behaves as you specified. Your submission mechanics are good! You might want to look into signing a contributor's agreement: http://docs.python.org/devguide/coredev.html#sign-a-cont

[issue17943] AttributeError: 'long' object has no attribute 'release' in Queue.put()

2013-05-08 Thread Georg Brandl
New submission from Georg Brandl: I'm a bit puzzled by this exception in a long-running process (running on Python 2.7.3): ... File "/usr/lib/python2.7/Queue.py", line 138, in put self.not_empty.notify() item = ('message', '\x80\x02]q\x01(U\x05nicosq\x02GA\xd4b\xcc

[issue17942] IDLE Debugger: names, values misaligned

2013-05-08 Thread Terry J. Reedy
New submission from Terry J. Reedy: The IDLE debugger has subwindows to display name-object bindings for locals and (optionally) globals. They have a gray background. Text is black, object strings get a white background box. The issue is that the white box and text for each name is slightly ra

[issue14146] IDLE: source line in editor doesn't highlight when debugging

2013-05-08 Thread Terry J. Reedy
Terry J. Reedy added the comment: 64 bit Win 7 with 32 bit debug build. Patch imported cleanly with all 3 branches. I cannot currently test 2.7. On 3.3 and 3.4, debugger worked fine relative to this issue: editor window highlight tracked line displayed in debugger as far as I checked. Normal se

[issue17927] Argument copied into cell still referenced by frame

2013-05-08 Thread Guido van Rossum
Guido van Rossum added the comment: I thought about that but I like this version better because the super() code does not have to know the details of how to find the cell. On Wednesday, May 8, 2013, Nick Coghlan wrote: > > Nick Coghlan added the comment: > > Guido, did you try combining your fi

[issue16584] unhandled IOError filecmp.cmpfiles() if file not readable

2013-05-08 Thread Terry J. Reedy
Terry J. Reedy added the comment: I don't use filecmp and cannot reproduce problem on Windows, for reason stated, but this looks correct, so I am taking Till's word that this fixes the problem, at least for him. Intentionally applied to 2.7 only for reason stated by Andrew. Till, if you submi

[issue17941] namedtuple should support fully qualified name for more portable pickling

2013-05-08 Thread Eli Bendersky
New submission from Eli Bendersky: [this came up as part of the Enum discussions. Full details in this thread: http://mail.python.org/pipermail/python-dev/2013-May/126076.html] namedtuple currently uses this code to obtain the __module__ for the class it creates dynamically so that pickling wo

[issue16584] unhandled IOError filecmp.cmpfiles() if file not readable

2013-05-08 Thread Roundup Robot
Roundup Robot added the comment: New changeset 1823cf6e1084 by Terry Jan Reedy in branch '2.7': Issue 16584: in filecomp._cmp, catch IOError as well as os.error. http://hg.python.org/cpython/rev/1823cf6e1084 -- nosy: +python-dev ___ Python tracker

[issue16584] unhandled IOError filecmp.cmpfiles() if file not readable

2013-05-08 Thread Terry J. Reedy
Changes by Terry J. Reedy : -- assignee: -> terry.reedy ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe: http:/

[issue17927] Argument copied into cell still referenced by frame

2013-05-08 Thread Nick Coghlan
Nick Coghlan added the comment: Guido, did you try combining your first patch (clearing the local var when populating the cell) with your second patch (by only checking for a cell when the local var is cleared rather than when it is populated)? It seems slightly more logical to me to have a ce

[issue17656] Python 2.7.4 breaks ZipFile extraction of zip files with unicode member paths

2013-05-08 Thread Antoine Pitrou
Changes by Antoine Pitrou : -- status: open -> closed ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe: http://ma

[issue17908] Unittest runner needs an option to call gc.collect() after each test

2013-05-08 Thread Guido van Rossum
Guido van Rossum added the comment: TBH I would *love* for there to be a standardized way to extend the command line options! If it existed I would help myself. As it is, that's way to complicated. (Then again, most customizations to the default test runner are too complicated IMO. :-) ---

[issue17908] Unittest runner needs an option to call gc.collect() after each test

2013-05-08 Thread Michael Foord
Michael Foord added the comment: I'm afraid I'm inclined to agree with Antoine. This seems a relatively specialised problem and I'd expect to see it solved in the test system rather than in unittest itself. One solution, and something I'd like to see, is a way for test systems to extend the u

[issue11354] argparse: nargs could accept range of options count

2013-05-08 Thread paul j3
paul j3 added the comment: Wouldn't it be simpler to use the re {m,n} notation to grab the appropriate number of arguments? In ArgumentParser _get_nargs_pattern we could add: +# n to m arguments, nargs is re like {n,m} +elif is_mnrep(nargs): +nargs_pattern = '([-A

[issue17940] extra code in argparse.py

2013-05-08 Thread Alex
New submission from Alex: In class HelpFormatter, class _Section, format_help(self) (lines 199 & 200), the two lines for func, args in self.items: func(*args) aren't necessary; the results of func are ignored. "func" is applied (again) on the next line when the outpu

[issue17927] Argument copied into cell still referenced by frame

2013-05-08 Thread Antoine Pitrou
Antoine Pitrou added the comment: +1 for a unit test! -- nosy: +pitrou ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubs

[issue17927] Argument copied into cell still referenced by frame

2013-05-08 Thread Amaury Forgeot d'Arc
Amaury Forgeot d'Arc added the comment: with a unit test maybe? -- nosy: +amaury.forgeotdarc ___ Python tracker ___ ___ Python-bugs-li

[issue17576] PyNumber_Index() is not int-subclass friendly (or operator.index() docos lie)

2013-05-08 Thread Terry J. Reedy
Changes by Terry J. Reedy : -- versions: -Python 3.1, Python 3.2 ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe

[issue17927] Argument copied into cell still referenced by frame

2013-05-08 Thread Guido van Rossum
Guido van Rossum added the comment: Ok, if I don't hear from anyone soon I'm going to commit. -- ___ Python tracker ___ ___ Python-bug

[issue17939] Misleading information about slice assignment in docs

2013-05-08 Thread Ezio Melotti
Changes by Ezio Melotti : -- nosy: +ezio.melotti ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.py

[issue17938] Duplicate text in docs/reference/import statement

2013-05-08 Thread Ezio Melotti
Changes by Ezio Melotti : -- nosy: +ezio.melotti ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.py

[issue17939] Misleading information about slice assignment in docs

2013-05-08 Thread Stefan Chrobot
New submission from Stefan Chrobot: http://docs.python.org/3/reference/simple_stmts.html#assignment-statements The docs says: "If the target is a slicing: The primary expression in the reference is evaluated. It should yield a mutable sequence object (such as a list). The assigned object shou

[issue17938] Duplicate text in docs/reference/import statement

2013-05-08 Thread Stefan Chrobot
New submission from Stefan Chrobot: http://docs.python.org/3/reference/simple_stmts.html#the-import-statement After the "Examples", there's a duplicated paragraph: The public names defined by a module are determined by checking the module’s namespace for a variable named __all__; if defined, i

[issue17937] Collect garbage harder at shutdown

2013-05-08 Thread Antoine Pitrou
New submission from Antoine Pitrou: This is a patch to collect cyclic garbage one more time when all modules have been cleared. -- components: Interpreter Core files: gc_hard.patch keywords: patch messages: 188736 nosy: pitrou priority: low severity: normal stage: patch review status: o

[issue17912] thread states should use a doubly-linked list

2013-05-08 Thread Charles-François Natali
Changes by Charles-François Natali : -- resolution: -> fixed stage: patch review -> committed/rejected status: open -> closed ___ Python tracker ___

[issue17930] Search not needed in combinations_with_replacement

2013-05-08 Thread Tim Peters
Tim Peters added the comment: There's another savings to be had when an index becomes the maximum: in that case, all the indices to its right are already at the maximum, so no need to overwrite them. This isn't as big a savings as skipping the search, but still buys about 10% more in the Pyt

[issue17656] Python 2.7.4 breaks ZipFile extraction of zip files with unicode member paths

2013-05-08 Thread Serhiy Storchaka
Changes by Serhiy Storchaka : -- resolution: -> fixed ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe: http://m

[issue17935] Failed compile on XP buildbot

2013-05-08 Thread Antoine Pitrou
Antoine Pitrou added the comment: Yes, the test_ssl failure is orthogonal. Thanks for fixing the compile issue! -- resolution: -> fixed stage: -> committed/rejected status: open -> closed ___ Python tracker _

[issue17912] thread states should use a doubly-linked list

2013-05-08 Thread Roundup Robot
Roundup Robot added the comment: New changeset 375d4fed4cf2 by Charles-Francois Natali in branch 'default': Issue #17912: Use a doubly linked-list for thread states. http://hg.python.org/cpython/rev/375d4fed4cf2 -- nosy: +python-dev ___ Python tracker

[issue17935] Failed compile on XP buildbot

2013-05-08 Thread David Bolen
David Bolen added the comment: Yeah, the XP buildbot was pretty old, at nasm 2.02, so I updated to the same 2.09 as the Win7 buildbot, restarted the last build and it went through compilation fine. However, then it failed in test_ssl, and in checking, it looks like my Win7 buildbot is failing

[issue17656] Python 2.7.4 breaks ZipFile extraction of zip files with unicode member paths

2013-05-08 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: Sorry, I thought I had corrected this test. -- ___ Python tracker ___ ___ Python-bugs-list mailing

[issue17656] Python 2.7.4 breaks ZipFile extraction of zip files with unicode member paths

2013-05-08 Thread Roundup Robot
Roundup Robot added the comment: New changeset 8952fa2c475f by Serhiy Storchaka in branch '2.7': Issue #17656: Skip test_extract_unicode_filenames if the FS encoding http://hg.python.org/cpython/rev/8952fa2c475f -- ___ Python tracker

[issue11587] METH_KEYWORDS alone gives "METH_OLDARGS is no longer supported!"

2013-05-08 Thread Jesse Ogle
Jesse Ogle added the comment: Same error with Python 3.3.1 Objects/methodobject.c: PyCFunction_Call() Switch contains case for "METH_VARARGS | METH_KEYWORDS" but not "METH_KEYWORDS". I assume this is on purpose? -- nosy: +jogle versions: +Python 3.3 __

[issue17927] Argument copied into cell still referenced by frame

2013-05-08 Thread Mark Dickinson
Changes by Mark Dickinson : -- nosy: +mark.dickinson ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe: http://mai

[issue17927] Argument copied into cell still referenced by frame

2013-05-08 Thread Antoine Pitrou
Changes by Antoine Pitrou : -- nosy: +benjamin.peterson, brett.cannon, georg.brandl, ncoghlan ___ Python tracker ___ ___ Python-bugs-l

[issue17807] Generator cleanup without tp_del

2013-05-08 Thread Antoine Pitrou
Antoine Pitrou added the comment: Committing for now, we'll see what people say. -- resolution: -> fixed stage: patch review -> committed/rejected status: open -> closed ___ Python tracker

[issue17807] Generator cleanup without tp_del

2013-05-08 Thread Roundup Robot
Roundup Robot added the comment: New changeset c89febab4648 by Antoine Pitrou in branch 'default': Issue #17807: Generators can now be finalized even when they are part of a reference cycle. http://hg.python.org/cpython/rev/c89febab4648 -- nosy: +python-dev

[issue17936] O(n**2) behaviour when adding/removing classes

2013-05-08 Thread Antoine Pitrou
Antoine Pitrou added the comment: Funny, I had once noticed this theoretical problem, but it didn't seem to matter concretely, so I hadn't posted about it :) -- nosy: +pitrou stage: -> patch review title: O(2) behaviour when adding/removing classes -> O(n**2) behaviour when adding/rem

[issue17936] O(2) behaviour when adding/removing classes

2013-05-08 Thread Kristján Valur Jónsson
Kristján Valur Jónsson added the comment: Adding the code change patch -- Added file: http://bugs.python.org/file30179/subtype.patch ___ Python tracker ___ __

[issue17936] O(2) behaviour when adding/removing classes

2013-05-08 Thread Kristján Valur Jónsson
New submission from Kristján Valur Jónsson: We came across this curious phenomenon, when our progam was leaking dynamically created classes. It started spending CPU, to be fixed when gc was increased. The attached .py file demonstrates the problem. The problem is due to how child classes ar

[issue17921] explicit empty check instead of implicit booleaness

2013-05-08 Thread Barry A. Warsaw
Changes by Barry A. Warsaw : -- nosy: +barry ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python

[issue17862] itertools.chunks(iterable, size, fill=None)

2013-05-08 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: A week ago I implemented chunks() on C for issue17804. This is an equivalent of such Python code for unlimited sequences: def chunks(seq, size, start=0): for i in itertools.count(start, size): yield seq[i: i + size] or simpler for lim

[issue17927] Argument copied into cell still referenced by frame

2013-05-08 Thread Guido van Rossum
Guido van Rossum added the comment: Here's a new version that copies the cell into the arg slot instead of just clearing it, with matching code in super() that looks in the cell. I'd appreciate a review from another senior core dev. -- keywords: +needs review -patch Added file: http://

[issue17927] Argument copied into cell still referenced by frame

2013-05-08 Thread Guido van Rossum
Changes by Guido van Rossum : -- stage: needs patch -> patch review ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscri

[issue17807] Generator cleanup without tp_del

2013-05-08 Thread Antoine Pitrou
Antoine Pitrou added the comment: Updated patch keeping PyGen_NeedsFinalizing() for backwards compatibility (always returning 0). -- Added file: http://bugs.python.org/file30175/gen4.patch ___ Python tracker _

[issue17935] Failed compile on XP buildbot

2013-05-08 Thread Antoine Pitrou
New submission from Antoine Pitrou: OpenSSL fails compiling on the XP-4 buildbot. Judging by the errors below (snipped), the nasm version may be too old (?) to understand some of the assembler instructions used in the source. David, could you perhaps take a look? http://buildbot.python.org/all

[issue17911] Extracting tracebacks does too much work

2013-05-08 Thread Antoine Pitrou
Antoine Pitrou added the comment: Ok, I've spinned off the frame clearing suggestion to issue17934. -- ___ Python tracker ___ ___ Pyth

[issue17934] Add a frame method to clear expensive details

2013-05-08 Thread Antoine Pitrou
Changes by Antoine Pitrou : -- dependencies: +Generator cleanup without tp_del ___ Python tracker ___ ___ Python-bugs-list mailing lis

[issue17934] Add a frame method to clear expensive details

2013-05-08 Thread Antoine Pitrou
New submission from Antoine Pitrou: I think we may want to add a finalize() or close() method on frame objects which would clear all local variables (as well as dereference the globals dict, perhaps), after having optionally run a generator's close() method (if the frame belongs to a generator

[issue17858] Different documentation for identical methods

2013-05-08 Thread R. David Murray
R. David Murray added the comment: Added review comments with suggestions on improving the wording further. Once we agree on wording we could apply this to the _thread docs as well, I suppose. Ah, I see that one of the changes I found problematic was suggested by Ezio :) -- _

[issue17809] FAIL: test_expanduser when $HOME ends with /

2013-05-08 Thread Antoine Pitrou
Antoine Pitrou added the comment: Looks good to me. -- nosy: +pitrou stage: patch review -> commit review ___ Python tracker ___ ___ P

[issue17912] thread states should use a doubly-linked list

2013-05-08 Thread Antoine Pitrou
Antoine Pitrou added the comment: Your patch looks fine to me, thank you. -- ___ Python tracker ___ ___ Python-bugs-list mailing list

[issue1545463] New-style classes fail to cleanup attributes

2013-05-08 Thread Roundup Robot
Roundup Robot added the comment: New changeset 8a5bebea9fec by Antoine Pitrou in branch 'default': Issue #1545463: At shutdown, defer finalization of codec modules so that stderr remains usable. http://hg.python.org/cpython/rev/8a5bebea9fec -- ___ Py

[issue17932] Win64: possible integer overflow in iterobject.c

2013-05-08 Thread Ronald Oussoren
Ronald Oussoren added the comment: Create a class with a __getitem__ method but no __iter__: class Seq (object): def __len__(self): return 5 def __getitem__(self, idx): if idx > len(self): raise IndexError(idx) return idx * 2 i = iter(Seq()) --

[issue995907] memory leak with threads and enhancement of the timer class

2013-05-08 Thread R. David Murray
R. David Murray added the comment: I take your point; I knew there was something bothering me about how the tasks were handled but I didn't consciously see the bug. I like the idea of a ScheduledExecutor. Yael, thanks a lot for working through this, but I think we should probably close this

[issue17809] FAIL: test_expanduser when $HOME ends with /

2013-05-08 Thread koobs
koobs added the comment: Spoil Ezio and learn me some python dev guide conventions, with an updated patch generated via hg diff, containing a comment, and including a bug #ID reference -- Added file: http://bugs.python.org/file30174/test_posixpath_v2.diff _

[issue995907] memory leak with threads and enhancement of the timer class

2013-05-08 Thread Charles-François Natali
Charles-François Natali added the comment: IMO, this shouldn't be implemented atop thread, but ought to be a regular thread pool: this way, you won't get behind if some task takes too long to execute, the thread pool can start new threads as needed, and we get the general work submit/cancel (t

[issue17877] Skip test_variable_tzname when the zoneinfo database is missing

2013-05-08 Thread Ezio Melotti
Changes by Ezio Melotti : -- resolution: -> fixed stage: commit review -> committed/rejected status: open -> closed ___ Python tracker ___ __

[issue17877] Skip test_variable_tzname when the zoneinfo database is missing

2013-05-08 Thread Roundup Robot
Roundup Robot added the comment: New changeset f7b552020d44 by Ezio Melotti in branch '3.3': #17877: skip test if the Olson's TZ database is missing. http://hg.python.org/cpython/rev/f7b552020d44 New changeset 492eba054e59 by Ezio Melotti in branch 'default': #17877: merge with 3.3. http://hg.py

[issue17877] Skip test_variable_tzname when the zoneinfo database is missing

2013-05-08 Thread Ezio Melotti
Ezio Melotti added the comment: > The attached patch checks if /usr/share/zoneinfo or /usr/lib/zoneinfo exist FTR these two locations are described by `man tzfile`: """ This page describes the structure of the timezone files used by tzset(3). These files are typically found under one of the di

[issue16396] Importing ctypes.wintypes on Linux gives a traceback

2013-05-08 Thread Ezio Melotti
Ezio Melotti added the comment: That patch is more a workaround than an actual fix. Lib/ctypes/wintypes.py should either fail with an ImportError or be importable. For the former it's possible to catch the ValueError and turn it into an ImportError, or perhaps raise it if some precondition i

[issue16523] attrgetter and itemgetter signatures in docs need cleanup

2013-05-08 Thread Ezio Melotti
Ezio Melotti added the comment: Fixed, thanks for the review! -- assignee: docs@python -> ezio.melotti resolution: -> fixed stage: commit review -> committed/rejected status: open -> closed ___ Python tracker

[issue16523] attrgetter and itemgetter signatures in docs need cleanup

2013-05-08 Thread Roundup Robot
Roundup Robot added the comment: New changeset 6f2412f12bfd by Ezio Melotti in branch '3.3': #16523: improve attrgetter/itemgetter/methodcaller documentation. http://hg.python.org/cpython/rev/6f2412f12bfd New changeset c2000ce25fe8 by Ezio Melotti in branch 'default': #16523: merge with 3.3. htt

[issue17927] Argument copied into cell still referenced by frame

2013-05-08 Thread Phil Connell
Changes by Phil Connell : -- nosy: +isoschiz ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python

[issue17927] Argument copied into cell still referenced by frame

2013-05-08 Thread Phil Connell
Changes by Phil Connell : -- nosy: +pconnell ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python

[issue17870] Python does not provide PyLong_FromIntMax_t() or PyLong_FromUintMax_t() function

2013-05-08 Thread Mark Dickinson
Mark Dickinson added the comment: I'll take a look. -- assignee: -> mark.dickinson ___ Python tracker ___ ___ Python-bugs-list mailin