[issue11244] Negative tuple elements produce inefficient code.

2011-03-12 Thread Mark Dickinson
Mark Dickinson dicki...@gmail.com added the comment: Eugene's new patch looks good to me; +1 on applying it. Raymond, do you happen to remember why it was necessary to add the zero-check in the first place? -- ___ Python tracker

[issue9516] sysconfig: $MACOSX_DEPLOYMENT_TARGET mismatch: now 10.3 but 10.5 during configure

2011-03-12 Thread Ned Deily
Ned Deily n...@acm.org added the comment: Another way this issue can show up: when building Python itself. If Parser/Python.asdl needs to be built (as with a new source checkout), the makefile target executes a python script (Parser/asdl_c.py) via /usr/bin/env python (a bootstrap dependency).

[issue11244] Negative tuple elements produce inefficient code.

2011-03-12 Thread Nadeem Vawda
Changes by Nadeem Vawda nadeem.va...@gmail.com: -- nosy: +nvawda ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue11244 ___ ___ Python-bugs-list

[issue6981] locale.getdefaultlocale() envvars default code and documentation mismatch

2011-03-12 Thread Eugene Crosser
Eugene Crosser cros...@average.org added the comment: I don't know if the solution suggested in the report is right, but I can confirm the the current logic of getdefaultlocale() produces wrong results. I have LANG=en_US.UTF-8 LANGUAGE=en_US:en LC_CTYPE=ru_RU.UTF-8

[issue11131] decimal.py: plus/minus with ROUND_FLOOR

2011-03-12 Thread Roundup Robot
Roundup Robot devnull@devnull added the comment: New changeset d5fe8b33f711 by Mark Dickinson in branch '2.7': Issue 11131: Fix sign of zero result on plus and minus operations in ROUND_FLOOR rounding mode. http://hg.python.org/cpython/rev/d5fe8b33f711 -- nosy: +python-dev

[issue11131] decimal.py: plus/minus with ROUND_FLOOR

2011-03-12 Thread Roundup Robot
Roundup Robot devnull@devnull added the comment: New changeset 1c4be28cda5b by Mark Dickinson in branch '3.1': Issue 11131: Fix sign of zero result on decimal.Decimal plus and minus operations in ROUND_FLOOR rounding mode. http://hg.python.org/cpython/rev/1c4be28cda5b New changeset

[issue11131] decimal.py: plus/minus with ROUND_FLOOR

2011-03-12 Thread Mark Dickinson
Mark Dickinson dicki...@gmail.com added the comment: Fixed in 2.7, 3.1, 3.2, 3.3. Closing. -- resolution: - fixed status: open - closed versions: +Python 3.1 ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue11131

[issue6981] locale.getdefaultlocale() envvars default code and documentation mismatch

2011-03-12 Thread Steffen Daode Nurpmeso
Steffen Daode Nurpmeso sdao...@googlemail.com added the comment: Eugene: i disagree. The semantics are correct according to C standards: http://pubs.opengroup.org/onlinepubs/009695399/basedefs/xbd_chap08.html -- nosy: +sdaoden ___ Python

[issue1099] Mac compile fails with pydebug and framework enabled

2011-03-12 Thread Ned Deily
Ned Deily n...@acm.org added the comment: The patch, as is, fixes another build failure mode that has been reported (http://article.gmane.org/gmane.comp.python.general/685151): ./configure --enable-framework ; make I verified that 3.2 builds without the patch fail on both 10.5 ppc and 10.4

[issue6981] locale.getdefaultlocale() envvars default code and documentation mismatch

2011-03-12 Thread Antoine Pitrou
Changes by Antoine Pitrou pit...@free.fr: -- nosy: +eric.araujo ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue6981 ___ ___ Python-bugs-list

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

2011-03-12 Thread Graham Wideman
Graham Wideman initcont...@grahamwideman.com added the comment: Thanks to all for your patient comments. I think I am resigned to raw-string forever being medium-rare-string :-). Perhaps it's obvious once you get over the initial shock of non-rawness, but workarounds for the disallowed

[issue6981] locale.getdefaultlocale() envvars default code and documentation mismatch

2011-03-12 Thread Steffen Daode Nurpmeso
Steffen Daode Nurpmeso sdao...@googlemail.com added the comment: (Eugene, whereas i still disagree (i'm a C programmer in daily life), Python 3.3a0 (default, Mar 10 2011, 11:50:55) [GCC 4.2.1 (Apple Inc. build 5664)] on darwin Type help, copyright, credits or license for more information.

[issue6981] locale.getdefaultlocale() envvars default code and documentation mismatch

2011-03-12 Thread Eugene Crosser
Eugene Crosser cros...@average.org added the comment: Steffen: can you please be more specific? As I read the seciton 8.2 of the cited document, I do not see a disparity with my statement. There is even an example: For example, if a user wanted to interact with the system in French, but

[issue6981] locale.getdefaultlocale() envvars default code and documentation mismatch

2011-03-12 Thread Steffen Daode Nurpmeso
Steffen Daode Nurpmeso sdao...@googlemail.com added the comment: On Sat, Mar 12, 2011 at 12:54:08PM +, Eugene Crosser wrote: Steffen: can you please be more specific? I can't, dear Eugene, because you are completely right and i am completely wrong. I believe that the correct guessing

[issue2142] difflib.unified_diff(...) produces invalid patches

2011-03-12 Thread Éric Araujo
Éric Araujo mer...@netwok.org added the comment: Patch does not look bad. I re-read the discussion on python-dev, where it was suggested to add a keyword argument to get the old behavior. Have you considered it? -- versions: +Python 3.3 -Python 3.2

[issue10461] Use with statement throughout the docs

2011-03-12 Thread Roundup Robot
Roundup Robot devnull@devnull added the comment: New changeset cebaf1bdaf78 by Éric Araujo in branch 'default': Fix example in atexit doc: Both open and read could raise the IOError (#10461 follow-up). http://hg.python.org/cpython/rev/cebaf1bdaf78 -- status: pending - open

[issue10461] Use with statement throughout the docs

2011-03-12 Thread Éric Araujo
Éric Araujo mer...@netwok.org added the comment: Thanks for the catch! I was so used to the idiom where opening the file doesn’t fail but you protect the read or write that I didn’t think about the issue here. -- stage: commit review - committed/rejected status: open - closed

[issue11468] Improve unittest basic example in the doc

2011-03-12 Thread Éric Araujo
Éric Araujo mer...@netwok.org added the comment: LGTM. -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue11468 ___ ___ Python-bugs-list mailing

[issue9856] Change object.__format__(s) where s is non-empty to a DeprecationWarning

2011-03-12 Thread Roundup Robot
Roundup Robot devnull@devnull added the comment: New changeset ee259a4f3eee by Eric V. Smith in branch 'default': Issue 9856: Change object.__format__ with a non-empty format string from a PendingDeprecationWarning to a DeprecationWarning. http://hg.python.org/cpython/rev/ee259a4f3eee

[issue9856] Change object.__format__(s) where s is non-empty to a TypeError

2011-03-12 Thread Eric Smith
Eric Smith e...@trueblade.com added the comment: Next step is to make it a TypeError in 3.4. -- priority: normal - release blocker title: Change object.__format__(s) where s is non-empty to a DeprecationWarning - Change object.__format__(s) where s is non-empty to a TypeError versions:

[issue2142] difflib.unified_diff(...) produces invalid patches

2011-03-12 Thread Ray.Allen
Ray.Allen ysj@gmail.com added the comment: I re-read the discussion on python-dev, where it was suggested to add a keyword argument to get the old behavior. Have you considered it? IIUC, at the time of that discusstion, 3.2 is pre-beta so the suitable option is to add \No newline etc

[issue11474] url2pathname() handling of '/C|/' on Windows

2011-03-12 Thread Bastian Kleineidam
New submission from Bastian Kleineidam cal...@users.sourceforge.net: Python 2.7 on Windows converts the URL path '/C|/' to a naked drive letter 'C:'. C:\srcc:\Python27\python.exe -c import urllib;print urllib.url2pathname('/C|/') C: C:\src Expected and I believe the correct output would be

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

2011-03-12 Thread Steffen Daode Nurpmeso
Steffen Daode Nurpmeso sdao...@googlemail.com added the comment: This patch makes getpass.getpass() comply with the documented behaviour and fixes #11466. It will require no further adjustments for #11236 (except what valhallasw's patch does, of course). It applies cleanly to: 16:32

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

2011-03-12 Thread saffroy
saffroy saff...@gmail.com added the comment: I could spend some time on a small patch. Here are the changes I would consider: - netrc.authenticators() could return the first entry matching a given host (now it returns the last) - it could also accept an extra parameter (with default=None), a

[issue1099] Mac compile fails with pydebug and framework enabled

2011-03-12 Thread Ronald Oussoren
Ronald Oussoren ronaldousso...@mac.com added the comment: Good catch, and that would also allow dropping the change to configure.in (which would only ensure that -isysroot gets defined correctly). -- ___ Python tracker rep...@bugs.python.org

[issue11464] Call Mac API Crash via ctypes

2011-03-12 Thread Ronald Oussoren
Ronald Oussoren ronaldousso...@mac.com added the comment: yufun, you better ask on python-list or the pythonmac-sig e-mail list (http://www.python.org/community/sigs/current/pythonmac-sig/). The added bonus is that you'll get into contact with other users of Python on OSX. The ctypes API is

[issue11475] trunc in documentation of numbers.Real should math.trunc

2011-03-12 Thread MATSUI Tetsushi
New submission from MATSUI Tetsushi m...@users.sourceforge.net: In the documentation of numbers.Real: In short, those are: a conversion to float, trunc(), round(), math.floor(), math.ceil(), divmod(), //, %, , =, , and =. where only trunc is not linked if we look at it in html pages. This is

[issue11476] StreamHandler code broken by change of parameter name

2011-03-12 Thread follower
New submission from follower bugs.python@rancidbacon.com: The following change broke pre-existing code that used strm as the parameter name (as documented http://docs.python.org/release/2.6.6/library/logging.html#streamhandler):

[issue11475] trunc in documentation of numbers.Real should math.trunc

2011-03-12 Thread Benjamin Peterson
Benjamin Peterson benja...@python.org added the comment: 7fd06773c3c2 -- nosy: +benjamin.peterson resolution: - fixed status: open - closed ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue11475

[issue3132] implement PEP 3118 struct changes

2011-03-12 Thread Meador Inge
Meador Inge mead...@gmail.com added the comment: Is there still any interest in this work? -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue3132 ___

[issue3132] implement PEP 3118 struct changes

2011-03-12 Thread Mark Dickinson
Mark Dickinson dicki...@gmail.com added the comment: Yes, there's interest (at least here). I've just been really short on Python-time recently, so haven't found time to review your patch. -- ___ Python tracker rep...@bugs.python.org

[issue3132] implement PEP 3118 struct changes

2011-03-12 Thread Mark Dickinson
Mark Dickinson dicki...@gmail.com added the comment: I'm going to unassign for now; I still hope to look at this at some point, but can't see a time in the near future when it's going to happen. -- assignee: mark.dickinson - ___ Python tracker

[issue11329] PyEval_InitThreads() not safe before Py_Initialize()

2011-03-12 Thread Gediminas Liktaras
Gediminas Liktaras glikta...@gmail.com added the comment: I have attached a patch that fixes this issue. Please let me know if there are any problems. -- keywords: +patch nosy: +gliktaras Added file: http://bugs.python.org/file21094/issue11329-1.patch

[issue11477] Bug in code dispatching based on internal slots

2011-03-12 Thread Terry J. Reedy
New submission from Terry J. Reedy tjre...@udel.edu: Example (which can serve as testcase with buggy output corrected). class C(object): def __iter__(self): yield 'yes!' def __radd__(self, other): other.append('bug!') return other def __rmul__(self, other):

[issue11477] Bug in code dispatching based on internal slots

2011-03-12 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/issue11477 ___ ___

[issue10665] Expand unicodedata module documentation

2011-03-12 Thread Ezio Melotti
Ezio Melotti ezio.melo...@gmail.com added the comment: I think Georg said that non-ascii chars shouldn't be used directly in the rst files, and one of the reasons is that they break `make pdf` (I haven't tried though). I added him to the nosy. -- nosy: +georg.brandl

[issue11426] CSV examples can't close their files

2011-03-12 Thread Ezio Melotti
Ezio Melotti ezio.melo...@gmail.com added the comment: This should be now fixed in 3.x, but not on 2.7. -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue11426 ___

[issue11477] Bug in code dispatching based on internal slots

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

[issue11476] StreamHandler code broken by change of parameter name

2011-03-12 Thread Roundup Robot
Roundup Robot devnull@devnull added the comment: New changeset 6d56d2c63a04 by Vinay Sajip in branch '2.7': Fixes issue #11476: StreamHandler parameter name change documented. http://hg.python.org/cpython/rev/6d56d2c63a04 -- nosy: +python-dev ___

[issue11476] StreamHandler code broken by change of parameter name

2011-03-12 Thread Vinay Sajip
Changes by Vinay Sajip vinay_sa...@yahoo.co.uk: -- assignee: docs@python - vinay.sajip nosy: +vinay.sajip resolution: - fixed status: open - closed ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue11476

[issue670664] HTMLParser.py - more robust SCRIPT tag parsing

2011-03-12 Thread Ezio Melotti
Ezio Melotti ezio.melo...@gmail.com added the comment: Thanks for the patch, however it would be better if you could get a clone of the CPython repo and make a patch against it. The patch should also include tests. You can check http://docs.python.org/devguide/ for more information.

[issue10735] platform.architecture() gives misleading results for OS X multi-architecture executables

2011-03-12 Thread Ronald Oussoren
Ronald Oussoren ronaldousso...@mac.com added the comment: IMHO the change to 'bits' is bogus, it is supposed to return the bit-size of the executable, not that of the currently running executable. I'd return all executable bitsizes in bits as '32bit', '64bit' or '32bit,64bit' (as appropriate)

[issue3493] No Backslash (\) in IDLE 1.2.2

2011-03-12 Thread Ronald Oussoren
Ronald Oussoren ronaldousso...@mac.com added the comment: Do I understand it correctly when I write that you normally use Option+Slash to enter a backslash on your keyboard? That would explain why updating the keyboard bindings makes it possible to type a backslash. I'm not sure how we could

[issue5154] OSX broken poll testing doesn't work

2011-03-12 Thread Ronald Oussoren
Ronald Oussoren ronaldousso...@mac.com added the comment: Florent: I don't understand why the traceback you show is related to this issue. -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue5154

[issue11312] Confusing sentence in file.readline() doc

2011-03-12 Thread Benjamin Peterson
Benjamin Peterson benja...@python.org added the comment: c017695acf19 -- nosy: +benjamin.peterson resolution: - fixed status: open - closed ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue11312

[issue2771] Test issue

2011-03-12 Thread Antoine Pitrou
Changes by Antoine Pitrou pit...@free.fr: -- resolution: fixed - status: closed - open ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue2771 ___ ___

[issue2771] Test issue

2011-03-12 Thread Roundup Robot
Roundup Robot devnull@devnull added the comment: New changeset 93a15af3a8ce by Antoine Pitrou in branch 'default': fixes #2771 http://hg.python.org/test/rev/93a15af3a8ce -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue2771

[issue2771] Test issue

2011-03-12 Thread Roundup Robot
Roundup Robot devnull@devnull added the comment: New changeset acd842ea10e6 by Antoine Pitrou in branch 'default': closes #2771 http://hg.python.org/test/rev/acd842ea10e6 -- resolution: - fixed status: open - closed ___ Python tracker

[issue8933] Invalid detection of metadata version

2011-03-12 Thread Filip Gruszczyński
Filip Gruszczyński grusz...@gmail.com added the comment: Here is patch for distutils2. Or maybe you would prefer a patch made by hg export? -- Added file: http://bugs.python.org/file21095/disutils2_8933.patch ___ Python tracker

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

2011-03-12 Thread Torsten Landschoff
Torsten Landschoff t.landsch...@gmx.net added the comment: I would regard this as Type: resource usage, instead of performance. Given enough RAM, loading the whole directory at once will likely be faster. The downsides of os.listdir: a) You can't get a peek at the files so far, it's all or

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

2011-03-12 Thread Antoine Pitrou
Antoine Pitrou pit...@free.fr added the comment: I would like to have an iterator version as well, but I also dislike another function (especially the x prefix). How about adding a keyword argument to select iterator behaviour? Changing the return type based on an argument is generally frown

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

2011-03-12 Thread Martin v . Löwis
Martin v. Löwis mar...@v.loewis.de added the comment: The downsides of os.listdir: a) You can't get a peek at the files so far, it's all or nothing. I only wanted to know if a directory is empty and I have to read the whole thing just to throw it away (maybe I missed another library

[issue11282] 3.3 unittest document not kept consist with code

2011-03-12 Thread Ezio Melotti
Ezio Melotti ezio.melo...@gmail.com added the comment: Michael, what's the status of this? Do you think some of the removed methods should be added back even if they are marked as removed in 3.3 in the 3.2 doc? -- ___ Python tracker

[issue11478] Docs list nonexistant PyObject_CopyToData function

2011-03-12 Thread Thomas Wouters
New submission from Thomas Wouters tho...@python.org: The buffer docs on http://docs.python.org/c-api/buffer.html list PyObject_CopyToData, but no such function seems to exist. -- assignee: docs@python components: Documentation messages: 130717 nosy: docs@python, twouters priority:

[issue11478] Docs list nonexistant PyObject_CopyToData function

2011-03-12 Thread Thomas Wouters
Thomas Wouters tho...@python.org added the comment: Eh, I mean PyObject_CopyToObject. -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue11478 ___

[issue11478] Docs list nonexistant PyObject_CopyToObject function

2011-03-12 Thread Thomas Wouters
Changes by Thomas Wouters tho...@python.org: -- title: Docs list nonexistant PyObject_CopyToData function - Docs list nonexistant PyObject_CopyToObject function ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue11478

[issue2650] re.escape should not escape underscore

2011-03-12 Thread SilentGhost
SilentGhost ghost@gmail.com added the comment: Here is the latest patch for test_re incorporating review suggestions by Ezio and some improvements along the way. -- Added file: http://bugs.python.org/file21096/test_re.diff ___ Python tracker

[issue11479] Add discussion of trailing slash in raw string to tutorial

2011-03-12 Thread R. David Murray
New submission from R. David Murray rdmur...@bitdance.com: Here is a proposed addition to the tutorial noting the problem with using raw strings for windows paths and how to work around it. -- assignee: docs@python components: Documentation files: tutorial-raw-string.patch keywords:

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

2011-03-12 Thread R. David Murray
R. David Murray rdmur...@bitdance.com added the comment: I've opened issue 11479 with a proposed patch to the tutorial along the lines suggested by Graham. -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue1271

[issue7391] Re-title the Using Backslash to Continue Statements anti-idiom

2011-03-12 Thread Roundup Robot
Roundup Robot devnull@devnull added the comment: New changeset e34b09c69dd3 by Raymond Hettinger in branch 'default': Issue #7391: Remove outdated HOWTO with permission of its author. http://hg.python.org/cpython/rev/e34b09c69dd3 -- nosy: +python-dev

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

2011-03-12 Thread Glenn Linderman
Glenn Linderman v+pyt...@g.nevcal.com added the comment: On 3/12/2011 7:11 PM, R. David Murray wrote: R. David Murrayrdmur...@bitdance.com added the comment: I've opened issue 11479 with a proposed patch to the tutorial along the lines suggested by Graham. Which is good, for people that

[issue7391] Re-title the Using Backslash to Continue Statements anti-idiom

2011-03-12 Thread Raymond Hettinger
Raymond Hettinger rhettin...@users.sourceforge.net added the comment: I discussed this with Moshe today and he agreed that the document is out-of-date and should be removed. -- nosy: +moshez resolution: - fixed status: open - closed ___ Python

[issue3493] No Backslash (\) in IDLE 1.2.2

2011-03-12 Thread Peter Nielsen
Peter Nielsen peter.ev...@gmail.com added the comment: Yes, that is correct . Well, thanks for replying, anyway. I guess I'll have to use linux instead. On Sun, Mar 13, 2011 at 12:00 AM, Ronald Oussoren rep...@bugs.python.orgwrote: Ronald Oussoren ronaldousso...@mac.com added the comment:

[issue11426] CSV examples can't close their files

2011-03-12 Thread Roundup Robot
Roundup Robot devnull@devnull added the comment: New changeset 52e1ad467edd by Eli Bendersky in branch '2.7': Issue #11426: use 'with' statements on open files in CSV examples http://hg.python.org/cpython/rev/52e1ad467edd -- ___ Python tracker

[issue11426] CSV examples can't close their files

2011-03-12 Thread Eli Bendersky
Changes by Eli Bendersky eli...@gmail.com: -- resolution: - accepted status: open - closed ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue11426 ___

[issue11479] Add discussion of trailing slash in raw string to tutorial

2011-03-12 Thread Eli Bendersky
Eli Bendersky eli...@gmail.com added the comment: Would it not be better to just recommend Windows users not to put that last backslash in at all? IIUC it's only needed to later append file names to directory names, but that's better achieved with os.path.join -- nosy: +eli.bendersky

[issue11477] Bug in code dispatching based on internal slots

2011-03-12 Thread Terry J. Reedy
Terry J. Reedy tjre...@udel.edu added the comment: Second link to pydev should be http://mail.python.org/pipermail/python-dev/2011-March/109130.html -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue11477

[issue1635741] Interpreter seems to leak references after finalization

2011-03-12 Thread Ray.Allen
Ray.Allen ysj@gmail.com added the comment: Does the title of this issue accurately reflect the current status of the Python interpreter? Yes, here is the running result on current 3.3 latest code: [37182 refs] [39415 refs] [41607 refs] [43799 refs] [45991 refs] [48183 refs] [50375 refs]

[issue10735] platform.architecture() gives misleading results for OS X multi-architecture executables

2011-03-12 Thread Ned Deily
Ned Deily n...@acm.org added the comment: IMHO the change to 'bits' is bogus, it is supposed to return the bit-size of the executable, not that of the currently running executable. Perhaps but (1) the code currently does return the bit-size of the currently running executable if it can't