[issue1559298] test_popen fails on Windows if installed to Program Files

2010-01-15 Thread Florent Xicluna
Florent Xicluna la...@yahoo.fr added the comment: It is on Python 2.7a2 os.popen('C:\\Python27\\python.exe -c import sys; print sys.argv 42').read() '' os.popen('C:\\Python27\\python.exe -c import sys; print sys.argv 42').read() ['-c', '42']\n os.popen3('C:\\Python27\\python.exe -c

[issue7693] tarfile.extractall can't have unicode extraction path

2010-01-15 Thread Lars Gustäbel
Lars Gustäbel l...@gustaebel.de added the comment: In the 2.x branch tarfile is not prepared to deal with unicode pathnames at all. This changed in Python 3. The fact that it works anyway (in the majority of cases) to add filenames as unicode objects is pure coincidence - I suppose you have a

[issue7693] tarfile.extractall can't have unicode extraction path

2010-01-15 Thread Peter Bienstman
Peter Bienstman peter.bienst...@ugent.be added the comment: So what do suggest then as the best approach if I want to use unicode paths in tar files in Python 2.x in a way that is portable across different systems? -- ___ Python tracker

[issue7693] tarfile.extractall can't have unicode extraction path

2010-01-15 Thread Lars Gustäbel
Lars Gustäbel l...@gustaebel.de added the comment: First, use a string pathname for extractall(). Most likely, your script is going to work. Convert all pathnames to strings using sys.getfilesystemencoding() before you add() them. Ensure that all systems you are going to use the archives on

[issue3426] os.path.abspath with unicode argument should call os.getcwdu

2010-01-15 Thread Ronald Oussoren
Ronald Oussoren ronaldousso...@mac.com added the comment: abspath is basically dead code in macpath, the module is used to manipulate classic MacOS9-style paths and is no longer used as os.path on any supported platform (it used to be os.path on MacOS9). BTW. the module itself is not dead,

[issue6352] Compiler warning in unicodeobject.c

2010-01-15 Thread Ezio Melotti
Changes by Ezio Melotti ezio.melo...@gmail.com: -- components: +Interpreter Core nosy: +ezio.melotti priority: - normal stage: - patch review type: - compile error ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue6352

[issue5905] strptime fails in non-UTF locale

2010-01-15 Thread Ezio Melotti
Changes by Ezio Melotti ezio.melo...@gmail.com: -- nosy: +ezio.melotti, lemburg versions: -Python 3.0 ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue5905 ___

[issue5587] vars() no longer has a useful __repr__

2010-01-15 Thread Ezio Melotti
Changes by Ezio Melotti ezio.melo...@gmail.com: -- nosy: +ezio.melotti priority: - normal stage: - test needed type: - behavior versions: +Python 3.2 -Python 3.0 ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue5587

[issue5825] Patch to add remove method to tempfile.NamedTemporaryFile

2010-01-15 Thread Ezio Melotti
Changes by Ezio Melotti ezio.melo...@gmail.com: -- keywords: +needs review nosy: +ezio.melotti priority: - normal stage: - patch review ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue5825

[issue5684] test_zipfile writes in its test directory

2010-01-15 Thread Ezio Melotti
Changes by Ezio Melotti ezio.melo...@gmail.com: -- nosy: +ezio.melotti stage: - needs patch versions: -Python 3.0 ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue5684 ___

[issue7693] tarfile.extractall can't have unicode extraction path

2010-01-15 Thread Peter Bienstman
Peter Bienstman peter.bienst...@ugent.be added the comment: On Friday 15 January 2010 11:51:24 am Lars Gustäbel wrote: Lars Gustäbel l...@gustaebel.de added the comment: First, use a string pathname for extractall(). Most likely, your script is going to work. Convert all pathnames to

[issue5609] Create Unit Tests for nturl2path module

2010-01-15 Thread Ezio Melotti
Changes by Ezio Melotti ezio.melo...@gmail.com: -- nosy: +ezio.melotti priority: - normal stage: - patch review ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue5609 ___

[issue5905] strptime fails in non-UTF locale

2010-01-15 Thread Marc-Andre Lemburg
Marc-Andre Lemburg m...@egenix.com added the comment: The reason for this is that the strftime() C lib API is used to build localized month names. With your setting, you'll get French Latin-1 month names and those cannot be coerced to UTF-8 due to the accented characters in them. This works

[issue7706] Missing #include guards

2010-01-15 Thread Andrej Krpic
New submission from Andrej Krpic akrpi...@gmail.com: Patch provides consistency with include guards already present in core. This issue is somehow next step to #1495999 and #1492356. These headers are missing from MSVC when targeting MS Windows CE . HAVE_PROCESS_H already used in:

[issue7693] tarfile.extractall can't have unicode extraction path

2010-01-15 Thread Lars Gustäbel
Lars Gustäbel l...@gustaebel.de added the comment: I suppose you do not have a real problem here. I thought your problem was that you want to use unicode pathnames as input and output to tarfile. You don't need that. You want to transfer an archive from one system to another. You can do that

[issue7693] tarfile.extractall can't have unicode extraction path

2010-01-15 Thread Peter Bienstman
Peter Bienstman peter.bienst...@ugent.be added the comment: On Friday 15 January 2010 02:14:30 pm Lars Gustäbel wrote: Lars Gustäbel l...@gustaebel.de added the comment: I suppose you do not have a real problem here. I thought your problem was that you want to use unicode pathnames as

[issue2775] Implement PEP 3108

2010-01-15 Thread Florent Xicluna
Florent Xicluna la...@yahoo.fr added the comment: Modules hotshot and xmllib give deprecation warnings. But they are not part of PEP 3108 or PEP 4. -- nosy: +flox ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue2775

[issue5825] Patch to add remove method to tempfile.NamedTemporaryFile

2010-01-15 Thread Brian Curtin
Brian Curtin cur...@acm.org added the comment: You should use assertFalse in your test, as failIf is deprecated starting in 2.7. -- nosy: +brian.curtin ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue5825

[issue7705] libpython2.6.so is not linked correctly on FreeBSD when threads are enabled

2010-01-15 Thread Brian Curtin
Changes by Brian Curtin cur...@acm.org: -- keywords: +needs review priority: - normal stage: - patch review ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue7705 ___

[issue7632] dtoa.c: oversize b in quorem

2010-01-15 Thread Mark Dickinson
Mark Dickinson dicki...@gmail.com added the comment: I was considering downgrading this to 'normal'. Then I found Bug 8, and it's a biggie: 10.900012345678912345678912345 10.0 Now I'm thinking it should be upgraded to release blocker instead. The cause is in the _Py_strtod

[issue7632] dtoa.c: oversize b in quorem

2010-01-15 Thread Mark Dickinson
Mark Dickinson dicki...@gmail.com added the comment: Upgrading to release blocker. It'll almost certainly be fixed before the weekend is out. (And I will, of course, report it upstream.) -- priority: high - release blocker ___ Python tracker

[issue5825] Patch to add remove method to tempfile.NamedTemporaryFile

2010-01-15 Thread Antoine Pitrou
Antoine Pitrou pit...@free.fr added the comment: What is the point besides to reduce the need to import os.unlink, which sounds a bit futile to me? -- nosy: +pitrou ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue5825

[issue7689] Pickling of classes with a metaclass and copy_reg

2010-01-15 Thread Antoine Pitrou
Changes by Antoine Pitrou pit...@free.fr: -- nosy: +alexandre.vassalotti ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue7689 ___ ___

[issue1634034] Show expected token on syntax error

2010-01-15 Thread Antoine Pitrou
Changes by Antoine Pitrou pit...@free.fr: -- nosy: +benjamin.peterson versions: +Python 3.2 -Python 3.1 ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue1634034 ___

[issue7691] test_bsddb3 files are not always removed when test fails

2010-01-15 Thread Florent Xicluna
Changes by Florent Xicluna la...@yahoo.fr: -- resolution: - duplicate stage: test needed - status: open - closed superseder: - Windows buildbot occasional DBFileExistsError failures in test_bsddb3 ___ Python tracker rep...@bugs.python.org

[issue7269] Windows buildbot occasional DBFileExistsError failures in test_bsddb3

2010-01-15 Thread Florent Xicluna
Florent Xicluna la...@yahoo.fr added the comment: #7691 marked duplicate of this bug. I've set the current directory read-only to track this bug. There's a single TestCase which creates the file in the current directory instead of /tmp. All other bsddb tests use either

[issue1559298] test_popen fails on Windows if installed to Program Files

2010-01-15 Thread Florent Xicluna
Changes by Florent Xicluna la...@yahoo.fr: -- keywords: +buildbot ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue1559298 ___ ___ Python-bugs-list

[issue1670765] email.Generator: no header wrapping for multipart/signed

2010-01-15 Thread Martin von Gagern
Martin von Gagern martin.vgag...@gmx.net added the comment: Let's get some traction here, please! Attached is a test case which will demonstrate the issue. It includes the content of test5.eml as a string so that it won't require additional files. It produces both human-readable output and a

[issue7668] test_httpservers fails with non-ascii path

2010-01-15 Thread Florent Xicluna
Changes by Florent Xicluna la...@yahoo.fr: -- keywords: +buildbot stage: - needs patch ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue7668 ___ ___

[issue7667] test_doctest fails with non-ascii path

2010-01-15 Thread Florent Xicluna
Changes by Florent Xicluna la...@yahoo.fr: -- keywords: +buildbot priority: - normal stage: - test needed ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue7667 ___

[issue1670765] email.Generator: no header wrapping for multipart/signed

2010-01-15 Thread Brian Curtin
Changes by Brian Curtin cur...@acm.org: -- keywords: +needs review stage: test needed - patch review versions: +Python 3.1 -Python 3.0 ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue1670765

[issue7707] multiprocess.Queue operations during import can lead to deadlocks

2010-01-15 Thread Alon Zakai
New submission from Alon Zakai thoughtc...@gmail.com: Creating a multiprocessing.Queue and operating on it while being imported can lead to a deadlock. The attached file will work if run directly (python test.py) but will hang if imported from the interpreter (import test). Additional

[issue3426] os.path.abspath with unicode argument should call os.getcwdu

2010-01-15 Thread Florent Xicluna
Changes by Florent Xicluna la...@yahoo.fr: -- keywords: +buildbot ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue3426 ___ ___ Python-bugs-list

[issue5207] extend strftime/strptime format for RFC3339 and RFC2822

2010-01-15 Thread R. David Murray
R. David Murray rdmur...@bitdance.com added the comment: See also issue 655194. -- nosy: +r.david.murray priority: - normal stage: - test needed versions: +Python 3.2 ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue5207

[issue1670765] email.Generator: no header wrapping for multipart/signed

2010-01-15 Thread Brian Curtin
Brian Curtin cur...@acm.org added the comment: Martin, can you provide a true unit test? Lib\email\test\test_email.py has many examples, and something like this would fit in there. -- nosy: +brian.curtin stage: patch review - test needed ___ Python

[issue5207] extend strftime/strptime format for RFC3339 and RFC2822

2010-01-15 Thread R. David Murray
R. David Murray rdmur...@bitdance.com added the comment: I mean issue 665194. -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue5207 ___ ___

[issue6961] test_distutils failure

2010-01-15 Thread Florent Xicluna
Florent Xicluna la...@yahoo.fr added the comment: There's still similar failures on 3.1 branch only. Some buildbots which have reported the error: AMD64 Ubuntu ia64 Ubuntu alpha Debian AMD64 Gentoo http://www.python.org/dev/buildbot/all/builders/AMD64%20Ubuntu%203.1/builds/194

[issue6961] test_distutils failure

2010-01-15 Thread Florent Xicluna
Florent Xicluna la...@yahoo.fr added the comment: whoops... I missed #7591 which is a report for the same issue. -- resolution: - invalid status: open - closed ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue6961

[issue7591] test_distutils: test_get_platform fails on 3.1

2010-01-15 Thread Florent Xicluna
Florent Xicluna la...@yahoo.fr added the comment: Some buildbots which have reported the error: AMD64 Ubuntu ia64 Ubuntu alpha Debian AMD64 Gentoo -- nosy: +flox title: test_get_platform fails on 3.1 - test_distutils: test_get_platform fails on 3.1

[issue7708] test_xmlrpc fails with non-ascii path

2010-01-15 Thread Florent Xicluna
New submission from Florent Xicluna la...@yahoo.fr: Another buildbot failure (repeated on AMD64 Ubuntu wide). test_xmlrpc Exception happened during processing of request from ('127.0.0.1', 59299) Traceback (most recent call last): File

[issue7707] multiprocess.Queue operations during import can lead to deadlocks

2010-01-15 Thread R. David Murray
Changes by R. David Murray rdmur...@bitdance.com: -- nosy: +brett.cannon, jnoller ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue7707 ___ ___

[issue6252] logging midnight rotation

2010-01-15 Thread Peter Hansen
Peter Hansen pe...@engcorp.com added the comment: In the NEWS file, this was recorded as fixed using the wrong issue number. The entry reads Issue #5262: Fixed bug in next rollover time computation in TimedRotatingFileHandler. rather than Issue #6252. -- nosy: +peter9477

[issue4111] Add Systemtap/DTrace probes

2010-01-15 Thread Wilfredo Sanchez
Changes by Wilfredo Sanchez wsanc...@wsanchez.net: -- nosy: +wsanchez ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue4111 ___ ___ Python-bugs-list

[issue3445] Ignore missing attributes in functools.update_wrapper

2010-01-15 Thread Antoine Pitrou
Antoine Pitrou pit...@free.fr added the comment: The patch should come with an unit test (in Lib/test/test_functools.py). -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue3445 ___

[issue4111] Add Systemtap/DTrace probes

2010-01-15 Thread Glyph Lefkowitz
Changes by Glyph Lefkowitz gl...@divmod.com: -- nosy: +glyph ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue4111 ___ ___ Python-bugs-list mailing

[issue6897] imaplib fails during login

2010-01-15 Thread R. David Murray
Changes by R. David Murray rdmur...@bitdance.com: -- priority: - normal resolution: - duplicate stage: - committed/rejected status: open - closed superseder: - Imap lib implicit conversion from bytes to string type: - behavior ___ Python tracker

[issue7610] Cannot use both read and readline method in same ZipExtFile object

2010-01-15 Thread Antoine Pitrou
Antoine Pitrou pit...@free.fr added the comment: The documentation of io.BufferedIOBase.read() reads multiple raw reads may be issued to satisfy the byte count. I understood this language to mean satisfying read size is optional. Isn't it? It's the reverse actually. It means that

[issue1670765] email.Generator: no header wrapping for multipart/signed

2010-01-15 Thread Martin von Gagern
Martin von Gagern martin.vgag...@gmx.net added the comment: OK, here is a patch providing both two test cases and the fix for current trunk. Will probably hack something for python 3 as well, although there the Message.as_string approach works due to the new headerlength argument defaulting

[issue6963] Add worker process lifetime to multiprocessing.Pool - patch included

2010-01-15 Thread Charles Cazabon
Charles Cazabon charlesc-pyt...@pyropus.ca added the comment: Ping... two alphas into 2.7. Have you had a chance to review this functionality? Thanks. -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue6963

[issue7709] the msg parameters of PyUnit assertions, such as assertEqual, should not obscure the automated diagnostics, such as '%s != %s'

2010-01-15 Thread Phlip
New submission from Phlip phlip2...@gmail.com: The various assertions are not DRY when they force you to repeat any automatic diagnostic in a message string, if you provide it. Here's an example: def assertEqual(self, first, second, msg=None): self.assert_((first == second), msg

[issue6963] Add worker process lifetime to multiprocessing.Pool - patch included

2010-01-15 Thread Brian Curtin
Changes by Brian Curtin cur...@acm.org: -- keywords: +needs review priority: - normal stage: - patch review versions: +Python 3.2 -Python 3.1 ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue6963

[issue6939] shadows around the io truncate() semantics

2010-01-15 Thread Pascal Chambon
Pascal Chambon chambon.pas...@gmail.com added the comment: Is there anything I can do to help this patch making its way to the trunk ? I guess it'd be better if Python2.7 benefited from it, so that users don't run anymore the risk of relying of this undocumented and non-canonical truncate

[issue6939] shadows around the io truncate() semantics

2010-01-15 Thread Antoine Pitrou
Changes by Antoine Pitrou pit...@free.fr: Removed file: http://bugs.python.org/file15763/Buggy patch - to be forgotten ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue6939 ___

[issue6963] Add worker process lifetime to multiprocessing.Pool - patch included

2010-01-15 Thread Jesse Noller
Jesse Noller jnol...@gmail.com added the comment: I'm fine with the functionality; I'm going to test it out and look at committing it by mid-week next week. I apologize, I've been pretty maxed out. -- ___ Python tracker rep...@bugs.python.org

[issue6939] shadows around the io truncate() semantics

2010-01-15 Thread Antoine Pitrou
Antoine Pitrou pit...@free.fr added the comment: Looking at the patches: - if you want to remove code, please remove it; don't comment it out - please don't use C++-style comments (it will break on some compilers, produce warnings on others) - code lines should generally not be wider than 80

[issue843590] 'macintosh' encoding alias for 'mac_roman'

2010-01-15 Thread Martin von Gagern
Martin von Gagern martin.vgag...@gmx.net added the comment: Find attached (issue843590_rfc.patch) an implementation of the macintosh encoding as the RFC defines it. I don't suggest its inclusion; I would prefer the alias of this implementation, but either one is better than no 'macintosh'

[issue7610] Cannot use both read and readline method in same ZipExtFile object

2010-01-15 Thread Nir Aides
Nir Aides n...@winpdb.org added the comment: May be a good idea to clear this up in the documentation. http://en.wiktionary.org/wiki/may#Verb (modal auxiliary verb, defective) To have permission to. Used in granting permission and in questions to make polite requests. --

[issue7710] Inconsistent Exception for int() conversion

2010-01-15 Thread Florent Xicluna
New submission from Florent Xicluna la...@yahoo.fr: On Python 3: int('\0') Traceback (most recent call last): File stdin, line 1, in module UnicodeEncodeError: 'decimal' codec can't encode character '\x00' in position 0: invalid decimal Unicode string int('\01') Traceback (most recent

[issue843590] 'macintosh' encoding alias for 'mac_roman'

2010-01-15 Thread Martin von Gagern
Martin von Gagern martin.vgag...@gmx.net added the comment: And this patch (issue84359_alias.patch) is the alternative, 'macintosh' as an alias to 'mac_roman' as originally requested, along with a bunch of aliases registered with IANA. I'd prefer this approach over the preceding one, and hope

[issue7710] Inconsistent Exception for int() conversion

2010-01-15 Thread Florent Xicluna
Florent Xicluna la...@yahoo.fr added the comment: The null byte gives UnicodeEncodeError for other conversions too. Python 3: int('\0'), float('\0'), complex('\0') Python 2: int(u'\0'), long(u'\0'), float(u'\0'), complex(u'0') Traceback (most recent call last): File stdin, line 1, in

[issue7710] Inconsistent Exception for int() conversion

2010-01-15 Thread Jean-Paul Calderone
Jean-Paul Calderone exar...@divmod.com added the comment: Loosely related to issue4221. -- nosy: +exarkun ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue7710 ___

[issue2927] expose html.parser.unescape

2010-01-15 Thread Brian Curtin
Changes by Brian Curtin cur...@acm.org: -- keywords: +needs review priority: - normal stage: - patch review versions: +Python 2.7 -Python 2.6 ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue2927

[issue4221] inconsistent exception from int is confusing

2010-01-15 Thread Florent Xicluna
Changes by Florent Xicluna la...@yahoo.fr: -- nosy: +flox versions: +Python 2.7, Python 3.1, Python 3.2 -Python 2.5 ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue4221 ___

[issue4221] inconsistent exception from int is confusing

2010-01-15 Thread Florent Xicluna
Florent Xicluna la...@yahoo.fr added the comment: Python 3 gives same confusing error: int(b'\0', 999) Traceback (most recent call last): File stdin, line 1, in module ValueError: invalid literal for int() with base 999: b'\x00' int(b'x', 999) Traceback (most recent call last): File

[issue7639] bdist_msi fails on files with long names

2010-01-15 Thread Christoph Gohlke
Christoph Gohlke cgoh...@uci.edu added the comment: I can confirm this issue. It prevents building a IPython msi installer on Python 2.6 for Windows. A patch to the Directory.make_short function in msilib\__init__.py is attached. It falls back to generating prefix~pos filenames when a short

[issue7709] the msg parameters of PyUnit assertions, such as assertEqual, should not obscure the automated diagnostics, such as '%s != %s'

2010-01-15 Thread R. David Murray
R. David Murray rdmur...@bitdance.com added the comment: You are looking for this: http://docs.python.org/dev/py3k/library/unittest.html#unittest.TestCase.longMessage I wish it were the default, but at least it exists in 2.7 and 3.x. (It can't be the default for backward compatibility

[issue7639] bdist_msi fails on files with long names

2010-01-15 Thread Brian Curtin
Changes by Brian Curtin cur...@acm.org: -- keywords: +needs review priority: - normal stage: - test needed type: crash - behavior ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue7639 ___

[issue1670765] email.Generator: no header wrapping for multipart/signed

2010-01-15 Thread R. David Murray
Changes by R. David Murray rdmur...@bitdance.com: -- assignee: barry - r.david.murray nosy: +r.david.murray stage: test needed - patch review versions: +Python 2.7, Python 3.2 ___ Python tracker rep...@bugs.python.org

[issue7707] multiprocess.Queue operations during import can lead to deadlocks

2010-01-15 Thread Brett Cannon
Brett Cannon br...@python.org added the comment: Without looking at the multiprocessing code I am willing to guess that some code in that run() function is launching some code that runs in a thread that is performing an import, deadlocking on the import lock. Jesse, is that what could be

[issue2775] Implement PEP 3108

2010-01-15 Thread Brett Cannon
Brett Cannon br...@python.org added the comment: I don't know why hotshot was deprecated specifically for Python 3 as that was never directly part of the discussion for PEP 3108. As for xmllib, that is most likely an oversight. Either way they should get added to the relevant PEPs. --

[issue7610] Cannot use both read and readline method in same ZipExtFile object

2010-01-15 Thread R. David Murray
R. David Murray rdmur...@bitdance.com added the comment: I do not find the existing phrasing in the IO docs ambiguous, but since it is obviously possible to misinterpret it it would be good to clarify it. Can you suggest an alternate phrasing that would be clearer? -- nosy:

[issue7709] the msg parameters of PyUnit assertions, such as assertEqual, should not obscure the automated diagnostics, such as '%s != %s'

2010-01-15 Thread Brett Cannon
Changes by Brett Cannon br...@python.org: -- status: open - closed ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue7709 ___ ___ Python-bugs-list

[issue6939] shadows around the io truncate() semantics

2010-01-15 Thread Pascal Chambon
Pascal Chambon chambon.pas...@gmail.com added the comment: Allright, I shall fix all this asap. But it seems the C code for truncate is actually buggy in the current 2.6 _fileio.c, around line 680. CF code below : posobj = portable_lseek(fd, posobj, 0); - don't we lose the reference to the

[issue7632] dtoa.c: oversize b in quorem, and a menagerie of other bugs

2010-01-15 Thread Mark Dickinson
Mark Dickinson dicki...@gmail.com added the comment: Here's a patch for the release blocker. Eric, would you be interested in double checking the logic for this patch? Tim: No, I have to admit I didn't forsee quite this number of bugs. :) -- title: dtoa.c: oversize b in quorem -

[issue7632] dtoa.c: oversize b in quorem, and a menagerie of other bugs

2010-01-15 Thread Mark Dickinson
Mark Dickinson dicki...@gmail.com added the comment: issue7632_bug8.patch uploaded to Rietveld: http://codereview.appspot.com/186168 -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue7632

[issue1722] Undocumented urllib functions

2010-01-15 Thread Brian Curtin
Changes by Brian Curtin cur...@acm.org: -- keywords: +easy stage: - needs patch type: - feature request versions: +Python 2.6, Python 2.7, Python 3.1, Python 3.2 -Python 2.5 ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue1722

[issue7632] dtoa.c: oversize b in quorem, and a menagerie of other bugs

2010-01-15 Thread Eric Smith
Eric Smith e...@trueblade.com added the comment: It looks correct to me, assuming this comment is correct: /* scan back until we hit a nonzero digit. significant digit 'i' is s0[i] if i nd0, s0[i+1] if i = nd0. */ I didn't verify the comment itself. --

[issue6939] shadows around the io truncate() semantics

2010-01-15 Thread Antoine Pitrou
Antoine Pitrou pit...@free.fr added the comment: posobj = portable_lseek(fd, posobj, 0); - don't we lose the reference to the old posobj there, doing a memory leak ? It's a bit more subtle. Here, the first reference to posobj that you get is through the function arguments. You don't own that

[issue6939] shadows around the io truncate() semantics

2010-01-15 Thread Antoine Pitrou
Antoine Pitrou pit...@free.fr added the comment: He, roundup ate part of the code I pasted. Here it is again: import io [39516 refs] f = io.open(foo, wb, buffering=0) [39542 refs] f.truncate() 0L [39544 refs] f.truncate() 0L [39544 refs] f.truncate(2) 2 [39543 refs] f.truncate(2) 2 [39542

[issue6939] shadows around the io truncate() semantics

2010-01-15 Thread Antoine Pitrou
Antoine Pitrou pit...@free.fr added the comment: By the way, you witness the issue (less clearly though) by running the tests in debug mode, too: $ ./python -m test.regrtest -v test_io test_io test_BufferedIOBase_destructor (test.test_io.CIOTest) ... ok test_IOBase_destructor

[issue6690] BUILD_SET followed by COMPARE_OP (in) can be optimized if all items are consts

2010-01-15 Thread Antoine Pitrou
Antoine Pitrou pit...@free.fr added the comment: No, you can't rely on the repr of a frozenset with multiple items. You should find another way of testing (if you are brave you could match the frozenset(...) with a regex and eval() it). Some comments on the patch: - there's a line or two in

[issue7632] dtoa.c: oversize b in quorem, and a menagerie of other bugs

2010-01-15 Thread Eric Smith
Eric Smith e...@trueblade.com added the comment: I have a few minor comments posted on Rietveld, but nothing that would keep you from checking this in. -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue7632

[issue6690] BUILD_SET followed by COMPARE_OP (in) can be optimized if all items are consts

2010-01-15 Thread Dave Malcolm
Dave Malcolm dmalc...@redhat.com added the comment: Thanks for the suggestions. Attached is a revised version of the patch. - I believe I've fixed all tab/space issues in this version of the patch, though I may have missed some (http://www.python.org/dev/tools/ doesn't recommend an

[issue6690] BUILD_SET followed by COMPARE_OP (in) can be optimized if all items are consts

2010-01-15 Thread Raymond Hettinger
Raymond Hettinger rhettin...@users.sourceforge.net added the comment: Nice looking patch. -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue6690 ___

[issue3426] os.path.abspath with unicode argument should call os.getcwdu

2010-01-15 Thread Ezio Melotti
Ezio Melotti ezio.melo...@gmail.com added the comment: For consistency I updated all 4 the modules. If the tests pass on both Windows and Mac the patch should be ready to go in. -- Added file: http://bugs.python.org/file15902/issue3426-3.diff ___

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

2010-01-15 Thread Matthew Barnett
Matthew Barnett pyt...@mrabarnett.plus.com added the comment: issue2636-20100116.zip is a new version of the regex module. I've given up on the breadth-wise matching - it was too difficult finding a pattern structure that would work well for both depth-first and breadth-wise. It probably

[issue3445] Ignore missing attributes in functools.update_wrapper

2010-01-15 Thread Evan Klitzke
Evan Klitzke e...@eklitzke.org added the comment: New patch included, with a test case. I had wanted to check the classmethod __module__ thing directly, but that proved to be elusive, since the classmethod gets the __module__ attribute if the module is '__main__', and you can't delete that

[issue5063] python-2.6.spec doesn't build properly

2010-01-15 Thread Sean Reifschneider
Sean Reifschneider j...@tummy.com added the comment: Committed to release26-maint as 77514. Committed to trunk as 77515. Committed to 3k as 77516. -- resolution: - accepted stage: - committed/rejected status: open - closed ___ Python tracker

[issue7711] csv error name incorrect

2010-01-15 Thread Scott Kitterman
New submission from Scott Kitterman skl...@kitterman.com: Using the csv module I encountered an ASCII NUL in a file and got this error: _csv.Error: line contains NULL byte According to the documentation ( http://docs.python.org/library/csv.html#module-contents ) it should be csv.Error:.

[issue7712] Add a context manager to change cwd in test.test_support

2010-01-15 Thread Ezio Melotti
New submission from Ezio Melotti ezio.melo...@gmail.com: To simplify the tests that require a different CWD I wrote a context manager that allows to change the working directory. I used it on #3426 to test os.path.abspath() with ASCII and non-ASCII CWDs and realized that it can also be used

[issue5684] test_zipfile writes in its test directory

2010-01-15 Thread Ezio Melotti
Changes by Ezio Melotti ezio.melo...@gmail.com: -- dependencies: +Add a context manager to change cwd in test.test_support ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue5684 ___

[issue3426] os.path.abspath with unicode argument should call os.getcwdu

2010-01-15 Thread Ezio Melotti
Changes by Ezio Melotti ezio.melo...@gmail.com: -- dependencies: +Add a context manager to change cwd in test.test_support ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue3426 ___