[issue11244] Negative tuple elements produce inefficient code.

2011-03-11 Thread Mark Dickinson
Mark Dickinson dicki...@gmail.com added the comment: fold-0.patch looks good to me, but why do you include tests only for the float case (-0.0) and not the integer case (-0)? Style nitpick: def negzero(): return -(1.0-1.0) should be on two source lines, not one. --

[issue11009] urllib.splituser is not documented

2011-03-11 Thread Senthil Kumaran
Senthil Kumaran orsent...@gmail.com added the comment: splituser is an internal API. It has never been exposed through Docs anytime and there are good reasons for that too. We never want internal helper functions (even tough they don't startwith _) be exposed through docs as it may clutter

[issue11406] There is no os.listdir() equivalent returning generator instead of list

2011-03-11 Thread Martin v . Löwis
Martin v. Löwis mar...@v.loewis.de added the comment: http://lwn.net/Articles/216948/ Why kernel.org is slow That's all independent of the issue at hand. Whether or not getdents is slow doesn't really matter here because we need to call getdents, anyway: it's the only API to get at the

[issue11009] urllib.splituser is not documented

2011-03-11 Thread Sandro Tosi
Sandro Tosi sandro.t...@gmail.com added the comment: Hi Senthil, what do you think about documenting those methods are private ones in the urllib code (if not using _, at least a short comment above them)? at least we have a mark it's an implementation decision and in case someone has the

[issue11406] There is no os.listdir() equivalent returning generator instead of list

2011-03-11 Thread Vetoshkin Nikita
Vetoshkin Nikita nikita.vetosh...@gmail.com added the comment: My benchmarks show that xlistdir() gives the only memory usage advantage on large directories. No speed gain so far - maybe my patch is wrong. -- ___ Python tracker

[issue11465] Set documentation: Link to wikipedia

2011-03-11 Thread Thomas Guettler
New submission from Thomas Guettler guet...@thomas-guettler.de: A link from http://docs.python.org/library/stdtypes.html#set.union to http://en.wikipedia.org/wiki/Union_%28set_theory%29 would help young people to understand sets. Of course it is the same for intersection(), difference(),

[issue11435] Links to source code should now point to hg repo

2011-03-11 Thread SilentGhost
SilentGhost ghost@gmail.com added the comment: This issue is not about the redirects. It is about links in documentation. The redirect is great for the links in the wild, the online documentation, however, could and should use proper links without any redirects. Georg, or whoever is

[issue11009] urllib.splituser is not documented

2011-03-11 Thread Senthil Kumaran
Senthil Kumaran orsent...@gmail.com added the comment: Sandro, I don't think is a required. Those functions serve the purpose of making the module code modular. They are helper functions for the module and are not really useful outside of it, when used standalone. Think about , splituser,

[issue9319] imp.find_module('test/badsyntax_pep3120') causes segfault

2011-03-11 Thread Łukasz Langa
Changes by Łukasz Langa luk...@langa.pl: -- nosy: +lukasz.langa ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue9319 ___ ___ Python-bugs-list

[issue11464] Call Mac API Crash via ctypes

2011-03-11 Thread Ned Deily
Ned Deily n...@acm.org added the comment: On OS X 10.6, the code segment segfaults for me in 64-bit mode but not in 32-bit mode. If you are using a 64-bit/32-bit Python 3.2, try running your failing code in 32-bit mode: arch -i386 python3.2 The 3.1.3 Python is most likely a 32-bit-only

[issue11466] getpass.getpass doesn't close tty file

2011-03-11 Thread Steffen Daode Nurpmeso
New submission from Steffen Daode Nurpmeso sdao...@googlemail.com: Here is a patch which cures the following ResourceWarning: unclosed file _io.TextIOWrapper name=3 mode='w+' encoding='UTF-8' (This only fixes the bug, not the rest of this code...) I did not try it out, but according to some

[issue11373] Fix 2 new typos in the docs

2011-03-11 Thread Boštjan Mejak
Boštjan Mejak bostjan.me...@gmail.com added the comment: Georg, please fix all the branches. Also, the online docs are still not updated with this fix. -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue11373

[issue11466] getpass.getpass doesn't close tty file

2011-03-11 Thread Antoine Pitrou
Changes by Antoine Pitrou pit...@free.fr: -- nosy: +gregory.p.smith ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue11466 ___ ___ Python-bugs-list

[issue11462] Peephole creates duplicate and unused constants

2011-03-11 Thread Antoine Pitrou
Antoine Pitrou pit...@free.fr added the comment: Style nit: you have tabs in your code. Please only use spaces for indentation. On the principle, looks worthwhile, and the changes don't look really complicated. -- nosy: +mark.dickinson ___ Python

[issue8036] Interpreter crashes on invalid arg to spawnl on Windows

2011-03-11 Thread Vetoshkin Nikita
Vetoshkin Nikita nikita.vetosh...@gmail.com added the comment: Attached first attempt to close this issue. Are there enough checks? It passes: os.spawnl(os.P_WAIT, '') os.spawnl(os.P_WAIT, 'path') os.spawnl(os.P_WAIT, 'path', '') -- keywords: +patch nosy: +nvetoshkin Added file:

[issue11466] getpass.getpass doesn't close tty file

2011-03-11 Thread Steffen Daode Nurpmeso
Steffen Daode Nurpmeso sdao...@googlemail.com added the comment: This new patch (11466.2.patch) also includes the #11236 patch, because if ^C would work as expected then that would not close the fd either. It's identical to the first patch beside that. -- Added file:

[issue11435] Links to source code should now point to hg repo

2011-03-11 Thread Roundup Robot
Roundup Robot devnull@devnull added the comment: New changeset 3c1e779002d3 by Ezio Melotti in branch '3.2': #11435: Update the links generated by the source directive to use hg.python.org. http://hg.python.org/cpython/rev/3c1e779002d3 -- nosy: +python-dev

[issue11236] getpass.getpass does not respond to ctrl-c or ctrl-z

2011-03-11 Thread Steffen Daode Nurpmeso
Steffen Daode Nurpmeso sdao...@googlemail.com added the comment: I do consider this as a bug, too (you hit ^C - and it doesn't help!)! I've opened #11466 due to a different problem, but since raising (the expected) KeyboardInterrupt would trigger that problem, too, i've included stripping

[issue11435] Links to source code should now point to hg repo

2011-03-11 Thread Ezio Melotti
Ezio Melotti ezio.melo...@gmail.com added the comment: Now it's fixed in 3.2 and 3.3. Thanks for the patch! -- resolution: - fixed stage: patch review - committed/rejected status: open - closed versions: +Python 3.2 ___ Python tracker

[issue11426] CSV examples can't close their files

2011-03-11 Thread Ezio Melotti
Ezio Melotti ezio.melo...@gmail.com added the comment: Patch looks good to me. The quotes are somewhat inconsistent (sometimes '' and sometimes ), if you want you can fix them while you are at it. -- ___ Python tracker rep...@bugs.python.org

[issue11467] urlparse.urlsplit() regression for paths consisting of digits

2011-03-11 Thread Bastian Kleineidam
New submission from Bastian Kleineidam cal...@users.sourceforge.net: When using a javascript URL with only digits as paths, the urlsplit() functions behaves different in Python 2.7 than in 2.6: $ python2.6 -c import urlparse; print urlparse.urlsplit('javascript:123')

[issue11426] CSV examples can't close their files

2011-03-11 Thread Roundup Robot
Roundup Robot devnull@devnull added the comment: New changeset f2a73d65422a by Eli Bendersky in branch 'default': Issue #11426: use 'with' statements on open files in CSV examples http://hg.python.org/cpython/rev/f2a73d65422a -- nosy: +python-dev ___

[issue11467] urlparse.urlsplit() regression for paths consisting of digits

2011-03-11 Thread Bastian Kleineidam
Changes by Bastian Kleineidam cal...@users.sourceforge.net: -- versions: +Python 3.2 ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue11467 ___ ___

[issue11426] CSV examples can't close their files

2011-03-11 Thread Eli Bendersky
Eli Bendersky eli...@gmail.com added the comment: SilentGhost: yep, thanks for the reminder :) -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue11426 ___

[issue2636] Regexp 2.7 (modifications to current re 2.2.2)

2011-03-11 Thread Alex
Changes by Alex alex.gay...@gmail.com: -- nosy: +alex ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue2636 ___ ___ Python-bugs-list mailing list

[issue11462] Peephole creates duplicate and unused constants

2011-03-11 Thread Eugene Toder
Eugene Toder elto...@gmail.com added the comment: Antoine, sure, I'll fix it with any other suggested changes if patches will be accepted. -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue11462

[issue11467] urlparse.urlsplit() regression for paths consisting of digits

2011-03-11 Thread Bastian Kleineidam
Bastian Kleineidam cal...@users.sourceforge.net added the comment: The behaviour change is caused by the fix for issue #754016. -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue11467 ___

[issue11454] email.message import time

2011-03-11 Thread Ross Lagerwall
Changes by Ross Lagerwall rosslagerw...@gmail.com: -- title: urllib.request import time - email.message import time ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue11454 ___

[issue11244] Negative tuple elements produce inefficient code.

2011-03-11 Thread Eugene Toder
Eugene Toder elto...@gmail.com added the comment: Mark, looks better now? -- Added file: http://bugs.python.org/file21082/fold-0.patch ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue11244 ___

[issue11426] CSV examples can't close their files

2011-03-11 Thread Roundup Robot
Roundup Robot devnull@devnull added the comment: New changeset 4cb0a8f5c952 by Eli Bendersky in branch 'default': Issue #11426: use 'with' statements on open files in CSV examples http://hg.python.org/cpython/rev/4cb0a8f5c952 New changeset d54e9c4fcd43 by Eli Bendersky in branch '3.1': Issue

[issue8995] Performance issue with multiprocessing queue (3.1 VS 2.6)

2011-03-11 Thread Antoine Pitrou
Antoine Pitrou pit...@free.fr added the comment: - 2.6: ('Using queue.Queue with small data: ', 0.77207708358764648) ('Using queue.Queue with huge data : ', 0.78139781951904297) ('Using multiprocessing.Queue with small data : ', 3.5506501197814941) ('Using

[issue11244] Negative tuple elements produce inefficient code.

2011-03-11 Thread Eugene Toder
Changes by Eugene Toder elto...@gmail.com: Removed file: http://bugs.python.org/file21082/fold-0.patch ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue11244 ___

[issue11244] Negative tuple elements produce inefficient code.

2011-03-11 Thread Eugene Toder
Eugene Toder elto...@gmail.com added the comment: (forgot parens around 0) -- Added file: http://bugs.python.org/file21083/fold-0.2.patch ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue11244

[issue10461] Use with statement throughout the docs

2011-03-11 Thread Éric Araujo
Éric Araujo mer...@netwok.org added the comment: Perhaps something should also be added to the doc style guide (along with using 'attributes' instead of 'members'). Terry, could you open another report for that, or maybe just commit the change directly? --

[issue1706039] Added clearerr() to clear EOF state

2011-03-11 Thread Alexander Belopolsky
Alexander Belopolsky belopol...@users.sourceforge.net added the comment: On Wed, Mar 9, 2011 at 2:32 AM, Scott Dial rep...@bugs.python.org wrote: .. By rejecting unittests on the merits of its coding style, you are creating a double-standard for people like me (outside of the core

[issue11244] Negative tuple elements produce inefficient code.

2011-03-11 Thread Roundup Robot
Roundup Robot devnull@devnull added the comment: New changeset 14205d0fee45 by Antoine Pitrou in branch 'default': Issue #11244: The peephole optimizer is now able to constant-fold http://hg.python.org/cpython/rev/14205d0fee45 -- nosy: +python-dev

[issue11244] Negative tuple elements produce inefficient code.

2011-03-11 Thread Antoine Pitrou
Antoine Pitrou pit...@free.fr added the comment: Ok, Eugene's patch is left to apply now. Can I assign this to you, Mark? -- assignee: - mark.dickinson ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue11244

[issue11462] Peephole creates duplicate and unused constants

2011-03-11 Thread Raymond Hettinger
Raymond Hettinger rhettin...@users.sourceforge.net added the comment: I'm disinclined to accept this patch. There is only minor space savings and no actual speed-up. When constant folding was introduced, a design decision was made to ignore the issue of orphan constants. The rationale

[issue11462] Peephole creates duplicate and unused constants

2011-03-11 Thread Antoine Pitrou
Antoine Pitrou pit...@free.fr added the comment: About dedup_const_planb.patch: _PyCode_AddObj() should be added to Include/code.h, even if it's private (rather than declared extern in peephole.c). About consts_test.patch: def mapping deserves a better name, and perhaps a comment or

[issue11462] Peephole creates duplicate and unused constants

2011-03-11 Thread Antoine Pitrou
Antoine Pitrou pit...@free.fr added the comment: Also, the peephole optimizer was developed before the AST branch was added to Python. Constant folding more properly belongs at the AST level, not in the peepholer itself. Our strategy is to move as much as possible into an AST optimizer and

[issue11462] Peephole creates duplicate and unused constants

2011-03-11 Thread Eugene Toder
Eugene Toder elto...@gmail.com added the comment: - why the #ifndef NDEBUG path? These entries in the table should not be used, but if something slips through and uses one of them, it's much easier to tell if we remap to invalid value. As this is an internal check, I didn't want it in release

[issue11462] Peephole creates duplicate and unused constants

2011-03-11 Thread Antoine Pitrou
Antoine Pitrou pit...@free.fr added the comment: - why the #ifndef NDEBUG path? These entries in the table should not be used, but if something slips through and uses one of them, it's much easier to tell if we remap to invalid value. As this is an internal check, I didn't want it in

[issue10461] Use with statement throughout the docs

2011-03-11 Thread Roundup Robot
Roundup Robot devnull@devnull added the comment: New changeset c3d28c84a372 by Éric Araujo in branch 'default': Use with statement where it improves the documentation (closes #10461) http://hg.python.org/cpython/rev/c3d28c84a372 -- nosy: +python-dev resolution: accepted - fixed status:

[issue11462] Peephole creates duplicate and unused constants

2011-03-11 Thread Eugene Toder
Eugene Toder elto...@gmail.com added the comment: assert() doesn't quite work here. I need to check that this entry in the table is not used in the next loop. I'd need to put assert in that loop, but by that time I have no easy way to tell which entries are bad, unless I mark them in the

[issue11462] Peephole creates duplicate and unused constants

2011-03-11 Thread Eugene Toder
Eugene Toder elto...@gmail.com added the comment: _PyCode_AddObj() should be added to Include/code.h Should it be declared as PyAPI_FUNC too? This will make it unnecessarily exported (when patch in Issue11410 is merged), so I wanted to avoid that. btw, that you for reviewing the patch.

[issue11467] urlparse.urlsplit() regression for paths consisting of digits

2011-03-11 Thread R. David Murray
Changes by R. David Murray rdmur...@bitdance.com: -- nosy: +orsenthil, r.david.murray ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue11467 ___ ___

[issue11462] Peephole creates duplicate and unused constants

2011-03-11 Thread Antoine Pitrou
Antoine Pitrou pit...@free.fr added the comment: _PyCode_AddObj() should be added to Include/code.h Should it be declared as PyAPI_FUNC too? This will make it unnecessarily exported (when patch in Issue11410 is merged), so I wanted to avoid that. I guess we don't usually try to optimize

[issue10461] Use with statement throughout the docs

2011-03-11 Thread SilentGhost
SilentGhost ghost@gmail.com added the comment: Éric, I'm not sure about the first atexit.rst hunk. I thought the purpose of that code was to except IOError when no file is found. I'm not entirely sure why in the simplest case infile.read() would raise IOError. I'd think that eli's patch

[issue11467] urlparse.urlsplit() regression for paths consisting of digits

2011-03-11 Thread Senthil Kumaran
Senthil Kumaran orsent...@gmail.com added the comment: What kind of url is 'javascript:123' and how do you (/ we) say that python2.6 behavior was correct? -- assignee: - orsenthil keywords: +patch ___ Python tracker rep...@bugs.python.org

[issue11462] Peephole creates duplicate and unused constants

2011-03-11 Thread Eugene Toder
Eugene Toder elto...@gmail.com added the comment: Right now, the pattern is tokenize - parse - AST - genbytecode - peephole optimization (which disassembles the bytecode, analyzed it and rewrites it) - final bytecode. The correct pattern is tokenize - parse - AST - optimize - genbytecode -

[issue11457] Expose nanosecond precision from system calls

2011-03-11 Thread Alexander Belopolsky
Changes by Alexander Belopolsky belopol...@users.sourceforge.net: -- nosy: +belopolsky ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue11457 ___ ___

[issue11457] Expose nanosecond precision from system calls

2011-03-11 Thread Alexander Belopolsky
Alexander Belopolsky belopol...@users.sourceforge.net added the comment: See also issue10812 which implements os.futimens(). -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue11457 ___

[issue11090] Doc errors for unittest in Python 3.1

2011-03-11 Thread Ezio Melotti
Ezio Melotti ezio.melo...@gmail.com added the comment: addCleanup/doCleanups/startTestRun/stopTestRun are in 3.1 too and now they are documented as new in 3.1. I also removed the versionchanged note for __iter__ (0f9e5042907c). Test discovery, --failfast, --catch, --buffer are new in 3.2 and

[issue11468] Improve unittest basic example in the doc

2011-03-11 Thread Ezio Melotti
New submission from Ezio Melotti ezio.melo...@gmail.com: The current example[0] uses assertTrue(element in self.seq) but it would be better to use assertIn instead. The whole example could be changed to something simpler that uses only the assertTrue/assertEqual/assertRaises methods

[issue11467] urlparse.urlsplit() regression for paths consisting of digits

2011-03-11 Thread Bastian Kleineidam
Bastian Kleineidam cal...@users.sourceforge.net added the comment: Regarding the correctness of the Python 2.6 implementation: http://www.faqs.org/rfcs/rfc1738.html specifies URLs of the form scheme:scheme-specific-part where the scheme specific part is allowed to consist only of digits. I

[issue11444] logging FileHandler.close should acquire its lock before closing stream

2011-03-11 Thread Roundup Robot
Roundup Robot devnull@devnull added the comment: New changeset d6626c9fc28d by Vinay Sajip in branch '2.6': Reverted bug fixes for #11444 (fc4d045e3170) and #11424 (b9d76846bb1c), which should not have been made in this branch. http://hg.python.org/cpython/rev/d6626c9fc28d --

[issue11446] Incorrect PEP link in Language Reference section 7.7

2011-03-11 Thread Roundup Robot
Roundup Robot devnull@devnull added the comment: New changeset ed1f7b3f2ff3 by Ezio Melotti in branch '3.1': #11446: fix incorrect PEP link. http://hg.python.org/cpython/rev/ed1f7b3f2ff3 -- nosy: +python-dev ___ Python tracker rep...@bugs.python.org

[issue11469] Fix resource warning in test_trailers

2011-03-11 Thread brian.curtin.test
New submission from brian.curtin.test brian.cur...@gmail.com: There is an unclosed file in test_trailers. Attaching a patch to fix this. -- components: Tests files: test_trailers_resourcefix.diff keywords: patch messages: 130602 nosy: brian.curtin.test priority: normal severity: normal

[issue11446] Incorrect PEP link in Language Reference section 7.7

2011-03-11 Thread Roundup Robot
Roundup Robot devnull@devnull added the comment: New changeset eeef2f17a774 by Ezio Melotti in branch '3.2': #11446: merge with 3.1. http://hg.python.org/cpython/rev/eeef2f17a774 -- ___ Python tracker rep...@bugs.python.org

[issue11446] Incorrect PEP link in Language Reference section 7.7

2011-03-11 Thread Roundup Robot
Roundup Robot devnull@devnull added the comment: New changeset 14a2d276b9ab by Ezio Melotti in branch 'default': #11446: merge with 3.2. http://hg.python.org/cpython/rev/14a2d276b9ab -- ___ Python tracker rep...@bugs.python.org

[issue11446] Incorrect PEP link in Language Reference section 7.7

2011-03-11 Thread Ezio Melotti
Ezio Melotti ezio.melo...@gmail.com added the comment: Thanks for the report! -- assignee: docs@python - ezio.melotti nosy: +ezio.melotti resolution: - fixed stage: - committed/rejected status: open - closed ___ Python tracker

[issue10812] Add some posix functions

2011-03-11 Thread Arfrever Frehtes Taifersar Arahesis
Changes by Arfrever Frehtes Taifersar Arahesis arfrever@gmail.com: -- nosy: +Arfrever ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue10812 ___

[issue11457] Expose nanosecond precision from system calls

2011-03-11 Thread Arfrever Frehtes Taifersar Arahesis
Changes by Arfrever Frehtes Taifersar Arahesis arfrever@gmail.com: -- nosy: +Arfrever ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue11457 ___

[issue11462] Peephole creates duplicate and unused constants

2011-03-11 Thread Raymond Hettinger
Changes by Raymond Hettinger rhettin...@users.sourceforge.net: -- nosy: +twouters -rhettinger ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue11462 ___

[issue11470] Flag inappropriate uses of callable class attributes

2011-03-11 Thread Thomas Wouters
New submission from Thomas Wouters tho...@python.org: As discussed at the language summit at PyCon 2011, some code takes some liberties with setting class attributes to callable objects, like CFunctions, that (C)Python does not turn into methods. This is problematic because 1) CPython can't

[issue11470] Flag inappropriate uses of callable class attributes

2011-03-11 Thread Andreas Stührk
Changes by Andreas Stührk andy-pyt...@hammerhartes.de: -- nosy: +Trundle ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue11470 ___ ___

[issue11470] Flag inappropriate uses of callable class attributes

2011-03-11 Thread Alex
Changes by Alex alex.gay...@gmail.com: -- nosy: +alex ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue11470 ___ ___ Python-bugs-list mailing list

[issue11469] Fix resource warning in test_trailers

2011-03-11 Thread Brian Curtin
Brian Curtin cur...@acm.org added the comment: FYI this was created during my PyCon talk...needed a non-dev account for the demo. -- nosy: +brian.curtin ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue11469

[issue1271] Raw string parsing fails with backslash as last character

2011-03-11 Thread Glenn Linderman
Glenn Linderman v+pyt...@g.nevcal.com added the comment: I can certainly agree with the opinion that raw strings are working as documented, but I can also agree with the opinion that they contain traps for the unwary, and after getting trapped several times, I have chosen to put up with the

[issue11470] Flag inappropriate uses of callable class attributes

2011-03-11 Thread Daniel Urban
Changes by Daniel Urban urban.dani...@gmail.com: -- nosy: +durban ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue11470 ___ ___ Python-bugs-list

[issue11179] ccbench doesn't work on 3.1/2.7

2011-03-11 Thread Roundup Robot
Roundup Robot devnull@devnull added the comment: New changeset 353032fd38e2 by Antoine Pitrou in branch '3.2': Issue #11179: Make ccbench work under Python 3.1 and 2.7 again. http://hg.python.org/cpython/rev/353032fd38e2 New changeset 92b59654e71c by Antoine Pitrou in branch 'default': Issue

[issue11179] ccbench doesn't work on 3.1/2.7

2011-03-11 Thread Antoine Pitrou
Changes by Antoine Pitrou pit...@free.fr: -- resolution: - fixed stage: needs patch - committed/rejected status: open - closed ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue11179 ___

[issue11462] Peephole creates duplicate and unused constants

2011-03-11 Thread Thomas Wouters
Changes by Thomas Wouters tho...@python.org: Added file: http://bugs.python.org/file21086/nonmethod-warn-nongit.diff ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue11462 ___

[issue11462] Peephole creates duplicate and unused constants

2011-03-11 Thread Thomas Wouters
Changes by Thomas Wouters tho...@python.org: Removed file: http://bugs.python.org/file21086/nonmethod-warn-nongit.diff ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue11462 ___

[issue11470] Flag inappropriate uses of callable class attributes

2011-03-11 Thread Thomas Wouters
Changes by Thomas Wouters tho...@python.org: Added file: http://bugs.python.org/file21087/nonmethod-warn-nongit.diff ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue11470 ___

[issue11470] Flag inappropriate uses of callable class attributes

2011-03-11 Thread Thomas Wouters
Changes by Thomas Wouters tho...@python.org: Removed file: http://bugs.python.org/file21085/nonmethod-warn.diff ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue11470 ___

[issue11470] Flag inappropriate uses of callable class attributes

2011-03-11 Thread Éric Araujo
Éric Araujo mer...@netwok.org added the comment: Don’t forget to remove the comments in codecs that are made obsolete by your changes. -- nosy: +eric.araujo ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue11470

[issue11470] Flag inappropriate uses of callable class attributes

2011-03-11 Thread Thomas Wouters
Changes by Thomas Wouters tho...@python.org: Added file: http://bugs.python.org/file21088/nonmethod-warn-nongit.diff ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue11470 ___

[issue11470] Flag inappropriate uses of callable class attributes

2011-03-11 Thread Thomas Wouters
Changes by Thomas Wouters tho...@python.org: Removed file: http://bugs.python.org/file21087/nonmethod-warn-nongit.diff ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue11470 ___

[issue9935] Faster pickling of instances

2011-03-11 Thread Roundup Robot
Roundup Robot devnull@devnull added the comment: New changeset ff0220c9d213 by Antoine Pitrou in branch 'default': Issue #9935: Speed up pickling of instances of user-defined classes. http://hg.python.org/cpython/rev/ff0220c9d213 -- nosy: +python-dev

[issue706263] print raises exception when no console available

2011-03-11 Thread Santoso Wijaya
Changes by Santoso Wijaya santoso.wij...@gmail.com: -- nosy: +santa4nt versions: +Python 2.7 ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue706263 ___

[issue706263] print raises exception when no console available

2011-03-11 Thread Santoso Wijaya
Changes by Santoso Wijaya santoso.wij...@gmail.com: -- components: +IO ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue706263 ___ ___

[issue9935] Faster pickling of instances

2011-03-11 Thread Antoine Pitrou
Changes by Antoine Pitrou pit...@free.fr: -- resolution: - fixed stage: patch review - committed/rejected status: open - closed ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue9935 ___

[issue11466] getpass.getpass doesn't close tty file

2011-03-11 Thread Éric Araujo
Changes by Éric Araujo mer...@netwok.org: Removed file: http://bugs.python.org/file21079/getpass_fdclose.patch ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue11466 ___

[issue1271] Raw string parsing fails with backslash as last character

2011-03-11 Thread R. David Murray
R. David Murray rdmur...@bitdance.com added the comment: I think perhaps the language in the language reference is a bit misleading. The purpose of the raw string algorithm is that any characters in the string be copied literally into the string object. That is, \ escapes the not so that

[issue11236] getpass.getpass does not respond to ctrl-c or ctrl-z

2011-03-11 Thread Éric Araujo
Éric Araujo mer...@netwok.org added the comment: Please do not mix issues. -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue11236 ___ ___

[issue11466] getpass.getpass doesn't close tty file

2011-03-11 Thread Éric Araujo
Éric Araujo mer...@netwok.org added the comment: Sorry, accidentally removed the first patch. -1 on the second patch: there’s another issue for that, and your patch is not uncontroversial. -- Added file: http://bugs.python.org/file21089/getpass_fdclose.patch

[issue11406] There is no os.listdir() equivalent returning generator instead of list

2011-03-11 Thread Éric Araujo
Changes by Éric Araujo mer...@netwok.org: -- nosy: +eric.araujo ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue11406 ___ ___ Python-bugs-list

[issue11428] with statement looks up __exit__ incorrectly

2011-03-11 Thread Éric Araujo
Éric Araujo mer...@netwok.org added the comment: After a quick perusal of the PEP, there are no wrong definitions of context managers (IOW they define methods in a class, not attribute on an object), but the pseudo-code explaining how the statement works use things like “mgr.__enter__”

[issue1099] Mac compile fails with pydebug and framework enabled

2011-03-11 Thread Ronald Oussoren
Ronald Oussoren ronaldousso...@mac.com added the comment: The attached patch removes the call to libtool and always links the framework using gcc (as was already done for universal builds). With this patch I can build the framework using the following configure command-line on OSX 10.6:

[issue11412] Section numbers in the Library Reference have a trailing period

2011-03-11 Thread Éric Araujo
Changes by Éric Araujo mer...@netwok.org: -- nosy: +eric.araujo ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue11412 ___ ___ Python-bugs-list

[issue11470] Flag inappropriate uses of callable class attributes

2011-03-11 Thread Guido van Rossum
Guido van Rossum gu...@python.org added the comment: This should not reuse DeprecationWarning but instead introduce a different warning, e.g. CompatibilityWarning. -- nosy: +gvanrossum ___ Python tracker rep...@bugs.python.org

[issue11416] netrc module does not handle multiple entries for a single host

2011-03-11 Thread Éric Araujo
Éric Araujo mer...@netwok.org added the comment: Thanks for the report. Would you like to work on a patch? Guidelines are found at http://docs.python.org/devguide -- nosy: +eric.araujo, rhettinger versions: +Python 2.7, Python 3.1, Python 3.2, Python 3.3 -Python 2.6

[issue11418] Method's global scope is module containing function definition, not class.

2011-03-11 Thread Éric Araujo
Éric Araujo mer...@netwok.org added the comment: I’m afraid I don’t understand “Method's function”. Could you rephrase, or give a commented code example showing the bad behavior? -- nosy: +eric.araujo versions: -Python 2.6 ___ Python tracker

[issue11466] getpass.getpass doesn't close tty file

2011-03-11 Thread Steffen Daode Nurpmeso
Steffen Daode Nurpmeso sdao...@googlemail.com added the comment: On Fri, Mar 11, 2011 at 09:20:14PM +, Éric Araujo wrote: your patch is not uncontroversial. The code is very ugly, but i think that somewhat reflects the code flow of the entire function. At least a bit. I've forced all

[issue11462] Peephole creates duplicate and unused constants

2011-03-11 Thread Thomas Wouters
Thomas Wouters tho...@python.org added the comment: What is the actual performance impact of this change? As far as I can see the difference is almost entirely in .pyc (on-disk) size, as when loading most of these constants are interned anyway. Even the on-disk change is minimal - and I say

[issue11419] Python-ast.[ch] out-of-date w.r.t. sources in fresh 2.5 checkout

2011-03-11 Thread Éric Araujo
Éric Araujo mer...@netwok.org added the comment: Some info: http://mercurial.selenic.com/wiki/FAQ#FAQ.2BAC8-CommonProblems.Why_is_the_modification_time_of_files_not_restored_on_checkout.3F and

[issue11471] If without else generates redundant jump

2011-03-11 Thread Eugene Toder
New submission from Eugene Toder elto...@gmail.com: If statement without else part generates unnecessary JUMP_FORWARD insn with jumps right to the next insn: def foo(x): if x: x = 1 dis(foo) 2 0 LOAD_FAST0 (x) 3 POP_JUMP_IF_FALSE 15

[issue11471] If without else generates redundant jump

2011-03-11 Thread Eugene Toder
Eugene Toder elto...@gmail.com added the comment: Test case (needed some refactoring to avoid duplication). -- Added file: http://bugs.python.org/file21092/if_no_else_test.patch ___ Python tracker rep...@bugs.python.org

[issue11466] getpass.getpass doesn't close tty file

2011-03-11 Thread Éric Araujo
Éric Araujo mer...@netwok.org added the comment: If you can write a patch that cleans up the code and closes the files without being too hard to review, it could get committed soon. Then you could adapt your patch on the other bug and defend it. --

  1   2   >