[issue14126] Speed up list comprehensions by preallocating the list where possible

2012-02-26 Thread Brett Cannon
Changes by Brett Cannon br...@python.org: -- nosy: +brett.cannon ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue14126 ___ ___ Python-bugs-list

[issue14133] improved PEP 409 implementation

2012-02-26 Thread Nick Coghlan
Nick Coghlan ncogh...@gmail.com added the comment: The other problem with the separate attribute approach is that it makes the condition for suppressing the context ugly: exc.__suppress_context__ or exc.__cause__ is not None That's hardly cleaner than: exc.__cause__ is not Ellipsis

[issue14133] improved PEP 409 implementation

2012-02-26 Thread Antoine Pitrou
Antoine Pitrou pit...@free.fr added the comment: The other problem with the separate attribute approach is that it makes the condition for suppressing the context ugly: exc.__suppress_context__ or exc.__cause__ is not None That's hardly cleaner than: exc.__cause__ is not Ellipsis

[issue14133] improved PEP 409 implementation

2012-02-26 Thread Nick Coghlan
Nick Coghlan ncogh...@gmail.com added the comment: Regardless, I'm rejecting this for not complying with the PEP specification (which is quite explicit about the implementation mechanism and the API exposed to Python). If you want to challenge an approved PEP, the correct way to go about it

[issue14007] xml.etree.ElementTree - XMLParser and TreeBuilder's doctype() method missing

2012-02-26 Thread Florent Xicluna
Florent Xicluna florent.xicl...@gmail.com added the comment: Two other differences: * the C TreeBuilder has an undocumented and unused method xml * if you omit one of the TreeBuilder method (start(), end(), data(), close()) on you custom TreeBuilder implementation, the C XMLParser works fine,

[issue13086] Update howto/cporting.rst so it talks about Python 3 instead of 3.0

2012-02-26 Thread Larry Hastings
Larry Hastings la...@hastings.org added the comment: Gah! This one fell through the cracks. Attached is an updated patch with Ezio's Python-level fix, and a little more paragraph tidying. (Apart from that one ^ dash, the only changes between r1 and r2 are eols.) Unless I hear otherwise,

[issue12904] Change os.utime c functions to use nanosecond precision where possible

2012-02-26 Thread Larry Hastings
Larry Hastings la...@hastings.org added the comment: This was committed last September; I should have marked it closed then. -- resolution: - fixed status: open - closed ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue12904

[issue14097] Improve the introduction page of the tutorial

2012-02-26 Thread Georg Brandl
Georg Brandl ge...@python.org added the comment: Well, I guess some people will always be blind to the finer distinctions in the scientific meaning of words... but that doesn't mean we should apply them where they don't. -- nosy: +georg.brandl ___

[issue13086] Update howto/cporting.rst so it talks about Python 3 instead of 3.0

2012-02-26 Thread Ezio Melotti
Ezio Melotti ezio.melo...@gmail.com added the comment: Note that the 2.7 docs now use a recent Sphinx too, so :c:macro: should work on all the 3 branches (so you don't have to use :cmacro: on 2.7 and :c:macro: on 3.x). -- ___ Python tracker

[issue14133] improved PEP 409 implementation

2012-02-26 Thread Georg Brandl
Georg Brandl ge...@python.org added the comment: FWIW, I agree with Nick: once we go as far as writing PEPs for smaller features, we should keep to the spec as accepted. -- nosy: +georg.brandl ___ Python tracker rep...@bugs.python.org

[issue11457] os.stat(): add new fields to get timestamps as Decimal objects with nanosecond resolution

2012-02-26 Thread Larry Hastings
Larry Hastings la...@hastings.org added the comment: Given Guido's rejection of PEP 410, this won't happen, so I'm closing this bug. Our BFDL has specifically rejected any of the complicated representations; he ruled that all we need are new _ns fields representing the time in nanoseconds,

[issue11941] Support st_atim, st_mtim and st_ctim attributes in os.stat_result

2012-02-26 Thread Larry Hastings
Larry Hastings la...@hastings.org added the comment: Given Guido's rejection of PEP 410, this won't happen, so I'm closing this bug. Our BFDL has specifically rejected any of the complicated representations; he ruled that all we need are new _ns fields representing the time in nanoseconds,

[issue14113] Failure in test_strptime on Windows

2012-02-26 Thread Nadeem Vawda
Nadeem Vawda nadeem.va...@gmail.com added the comment: Attached a fix that is tested on Windows. Patch looks good to me. Does test.support track the locale for test mutations? No, it doesn't. -- ___ Python tracker rep...@bugs.python.org

[issue11807] Documentation of add_subparsers lacks information about parametres

2012-02-26 Thread Filip Gruszczyński
Filip Gruszczyński grusz...@gmail.com added the comment: Bump! I would like to remind about this issue and patch. -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue11807 ___

[issue14007] xml.etree.ElementTree - XMLParser and TreeBuilder's doctype() method missing

2012-02-26 Thread Eli Bendersky
Eli Bendersky eli...@gmail.com added the comment: On Sun, Feb 26, 2012 at 23:49, Florent Xicluna rep...@bugs.python.orgwrote: Yes, these suggestions sound reasonable to me. Moving toward two more consistent implementations of the API, while not disabling existing features is the way to go.

[issue14134] xmlrpc.client.ServerProxy() -- need for timeout-parameter

2012-02-26 Thread Andrej A Antonov
New submission from Andrej A Antonov polymor...@gmail.com: good day! xmlrpc.client.ServerProxy() -- not has timeout-parameter xmlrpc.client.Transport() and xmlrpc.client.SafeTransport() -- not has timeout-parameter too but http.client.HTTPConnection() and http.client.HTTPSConnection() -- has

[issue13086] Update howto/cporting.rst so it talks about Python 3 instead of 3.0

2012-02-26 Thread Larry Hastings
Larry Hastings la...@hastings.org added the comment: Whoops--I hadn't updated my repo since last year, and someone had already changed to :c:macro:, :c:func:, and :c:type:. When will I learn! Attached is a new diff with those changes, against revision @4c6662090870 (on the 2.7 branch).

[issue13053] Add Capsule migration documentation to cporting

2012-02-26 Thread Larry Hastings
Larry Hastings la...@hastings.org added the comment: I have some more changes for cporting.rst (see #13086). Once those are in, I'll manually merge the edits over to 3.2, then forward-port to trunk. Does anyone want to see those as patches before I commit them? (Your silence will be

[issue14006] Improve the documentation of xml.etree.ElementTree

2012-02-26 Thread Florent Xicluna
Florent Xicluna florent.xicl...@gmail.com added the comment: FWIW, Fredrik, who is the creator of ElementTree, had a preference for JavaDoc conventions, as explained here: http://bugs.python.org/issue6488#msg102087 They are compatible with the tool PythonDoc, authored by Fredrik too:

[issue14113] Failure in test_strptime on Windows

2012-02-26 Thread STINNER Victor
STINNER Victor victor.stin...@gmail.com added the comment: Attached a fix that is tested on Windows. Patch looks good to me. -oldloc = locale.setlocale(locale.LC_ALL, '') +oldloc = locale.setlocale(locale.LC_ALL) Python provides locale.getlocale(). --

[issue14135] check for locale changes in test.support

2012-02-26 Thread Brett Cannon
New submission from Brett Cannon br...@python.org: Issue #14113 pointed out that test.support doesn't check if tests mucked with the locale after running. -- components: Tests keywords: easy messages: 154414 nosy: brett.cannon priority: normal severity: normal status: open title: check

[issue14113] Failure in test_strptime on Windows

2012-02-26 Thread Brett Cannon
Brett Cannon br...@python.org added the comment: Created issue14135 for having test.support check the locale to see if it has been changed. -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue14113

[issue14113] Failure in test_strptime on Windows

2012-02-26 Thread Nadeem Vawda
Nadeem Vawda nadeem.va...@gmail.com added the comment: Python provides locale.getlocale(). That was my initial thought too, but it seems that getlocale() doesn't accept LC_ALL as its argument: Traceback (most recent call last): File stdin, line 1, in module File

[issue14085] PyUnicode_WRITE: comparison is always true warnings

2012-02-26 Thread STINNER Victor
STINNER Victor victor.stin...@gmail.com added the comment: Castng to Py_UCS4 doesn't make the warning quiet. Does someone know how to make the warning quiet. If not, assertions can be removed from PyUnicode_WRITE. We might write a function for Python compiled in debug mode to add the

[issue14135] check for locale changes in test.support

2012-02-26 Thread Nadeem Vawda
Changes by Nadeem Vawda nadeem.va...@gmail.com: -- nosy: +nadeem.vawda ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue14135 ___ ___

[issue11457] os.stat(): add new fields to get timestamps as Decimal objects with nanosecond resolution

2012-02-26 Thread Larry Hastings
Changes by Larry Hastings la...@hastings.org: -- status: open - closed ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue11457 ___ ___

[issue13873] SIGBUS in test_big_buffer() of test_zlib on Debian bigmem buildbot

2012-02-26 Thread Roundup Robot
Roundup Robot devn...@psf.upfronthosting.co.za added the comment: New changeset fc43b051ae1c by Nadeem Vawda in branch '3.2': Issue #13873: Fix crash in test_zlib when running on a small (4GB) tmpfs. http://hg.python.org/cpython/rev/fc43b051ae1c --

[issue14129] Corrections for the extending doc

2012-02-26 Thread Eli Bendersky
Eli Bendersky eli...@gmail.com added the comment: There are some: XXX Need to ... Paragraphs scattered across the doc. These have no place in the official documentation. For placeholders, an issue can be created that lists all the things that need to be done. --

[issue14134] xmlrpc.client.ServerProxy() -- need for timeout-parameter

2012-02-26 Thread Martin v . Löwis
Changes by Martin v. Löwis mar...@v.loewis.de: -- versions: -Python 2.7 ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue14134 ___ ___

[issue14134] xmlrpc.client.ServerProxy() -- need for timeout-parameter

2012-02-26 Thread Martin v . Löwis
Changes by Martin v. Löwis mar...@v.loewis.de: -- nosy: +loewis ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue14134 ___ ___ Python-bugs-list

[issue14125] Windows: failures in refleak mode

2012-02-26 Thread sbt
sbt shibt...@gmail.com added the comment: The failures for test_multiprocessing and test_concurrent_futures seem to be caused by a leak in _multiprocessing.win32.WaitForMultipleObjects(). The attached patch fixes those leaks for me (on a 32 bit build). -- keywords: +patch nosy: +sbt

[issue13521] Make dict.setdefault() atomic

2012-02-26 Thread Roundup Robot
Roundup Robot devn...@psf.upfronthosting.co.za added the comment: New changeset 5c52e7c6d868 by Antoine Pitrou in branch '2.7': Issue #13521: dict.setdefault() now does only one lookup for the given key, making it atomic for many purposes. http://hg.python.org/cpython/rev/5c52e7c6d868

[issue13521] Make dict.setdefault() atomic

2012-02-26 Thread Roundup Robot
Roundup Robot devn...@psf.upfronthosting.co.za added the comment: New changeset 90572ccda12c by Antoine Pitrou in branch '3.2': Issue #13521: dict.setdefault() now does only one lookup for the given key, making it atomic for many purposes. http://hg.python.org/cpython/rev/90572ccda12c New

[issue13521] Make dict.setdefault() atomic

2012-02-26 Thread Antoine Pitrou
Antoine Pitrou pit...@free.fr added the comment: Thank you Filip! I've now committed the patch. -- resolution: - fixed stage: patch review - committed/rejected status: open - closed ___ Python tracker rep...@bugs.python.org

[issue14067] Avoid more stat() calls in importlib

2012-02-26 Thread Jim Jewett
Jim Jewett jimjjew...@gmail.com added the comment: As long as the interpreter knows about about files that *it* wrote, no repeat checks during startup seems utterly reasonable; sneaking in a new or changed file is inherently a race condition. I think it would also be reasonable for general

[issue14136] Simplify PEP 409 command line test and move it to test_cmd_line_script

2012-02-26 Thread Nick Coghlan
New submission from Nick Coghlan ncogh...@gmail.com: I stuffed up the review on one of the new tests in the PEP 409 patch - the one that checks if the exception context is suppressed correctly from the command line. That test should be drastically simplified and moved from test_raise to

[issue14137] GTK3 Segmentation fault from Warning: g_object_notify: assertion `G_IS_OBJECT (object)' failed

2012-02-26 Thread Narnie Harshoe
New submission from Narnie Harshoe signupnar...@gmail.com: Using the following code for a Gtk.CellRenderSpin results in the following error after changing the spin button several times. The error is: /usr/lib/python2.7/dist-packages/gi/types.py:43: Warning: g_object_notify: assertion

[issue14138] Ctrl-C does not terminate GTK3 Gtk.main() loop when program run from command line

2012-02-26 Thread Narnie Harshoe
New submission from Narnie Harshoe signupnar...@gmail.com: In a normal python program, Ctrl-C will set up a KeyboardInterrupt and terminate the program. This works with a normal python script, including GTK2 gtk.main(), but GTK3 Gtk.main() (even when used in a more robust GTK program that

[issue14127] os.stat and os.utime: allow preserving exact metadata

2012-02-26 Thread Ross Lagerwall
Changes by Ross Lagerwall rosslagerw...@gmail.com: -- nosy: +rosslagerwall ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue14127 ___ ___

[issue13703] Hash collision security issue

2012-02-26 Thread Roger Serwy
Roger Serwy roger.se...@gmail.com added the comment: After pulling the latest code, random.py no longer works since it tries to import urandom from os on both 3.3 and 2.7. -- nosy: +serwy ___ Python tracker rep...@bugs.python.org

[issue8170] Wrong Paths for distutils build --plat-name=win-amd64

2012-02-26 Thread Mark Hammond
Mark Hammond skippy.hamm...@gmail.com added the comment: I don't quite understand how the order will be wrong. Which earlier entry is causing the problem? OTOH though, I also don't quite understand how the build would work at all if a 32bit Python is used to invoke distutils with

[issue13703] Hash collision security issue

2012-02-26 Thread Benjamin Peterson
Benjamin Peterson benja...@python.org added the comment: Can you paste the error you're getting? 2012/2/26 Roger Serwy rep...@bugs.python.org: Roger Serwy roger.se...@gmail.com added the comment: After pulling the latest code, random.py no longer works since it tries to import urandom

[issue14137] GTK3 Segmentation fault from Warning: g_object_notify: assertion `G_IS_OBJECT (object)' failed

2012-02-26 Thread Ramchandra Apte
Ramchandra Apte maniandra...@gmail.com added the comment: Why do you think this is a bug in Python? I don't think this is a bug in Python. This might be bug in PyGTK or GTK which are third-party libraries. -- nosy: +ramchandra.apte ___ Python tracker

[issue13703] Hash collision security issue

2012-02-26 Thread Roger Serwy
Roger Serwy roger.se...@gmail.com added the comment: It was a false alarm. I didn't recompile python before running it with the latest /Lib files. My apologies. -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue13703

[issue14111] IDLE Debugger should handle interrupts

2012-02-26 Thread Roger Serwy
Roger Serwy roger.se...@gmail.com added the comment: I can confirm the issue Larry's raises. Attached is a patch against 2.7 to enable Ctrl+C interrupts for the debugger. The patch opens up the possibility of making Go a toggle button, but that would require some more plumbing (not included

[issue14129] Corrections for the extending doc

2012-02-26 Thread Eli Bendersky
Eli Bendersky eli...@gmail.com added the comment: Adding the documentation experts. I plan to apply a fix for these soon. If you guys have any objections, let me know. -- nosy: +eric.araujo, ezio.melotti, georg.brandl ___ Python tracker

[issue13405] Add DTrace probes

2012-02-26 Thread Marc Abramowitz
Marc Abramowitz msabr...@gmail.com added the comment: Hi Jesús, Yes, I'm on an x86 machine. A MacBook Pro with OS X 10.6.8. I'll try to hop on Google Talk during the week. I'm on the west coast of the U.S. (GMT-8) so it might be tricky to find a mutually good time. Here's the result of the

[issue13405] Add DTrace probes

2012-02-26 Thread Marc Abramowitz
Marc Abramowitz msabr...@gmail.com added the comment: All tests pass on OpenIndiana b151A (SunOS openindiana 5.11 oi_151a2 i86pc i386 i86pc Solaris). -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue13405

[issue14138] Ctrl-C does not terminate GTK3 Gtk.main() loop when program run from command line

2012-02-26 Thread Charles-François Natali
Charles-François Natali neolo...@free.fr added the comment: The behaviour under Gtk.main() should be changed to respond to the KeyboardInterrupt. Well, you should report that to (Py)GTK folks then :-) Either they set up a SIGINT handler, or they catch the KeyboardInterrupt exception, but

[issue14137] GTK3 Segmentation fault from Warning: g_object_notify: assertion `G_IS_OBJECT (object)' failed

2012-02-26 Thread Charles-François Natali
Charles-François Natali neolo...@free.fr added the comment: @Narnie This is the Python bug tracker, not the PyGTK one. You should report your problems on the PyGTK/GTK bug tracker. Thanks. -- nosy: +neologix resolution: - invalid stage: - committed/rejected status: open - closed

<    1   2