[issue8828] Atomic function to rename a file

2011-10-23 Thread Charles-François Natali
Charles-François Natali added the comment: > MoveFileTransacted is only available under Vista or later. You should be able > to use MoveFileEx for the same effect. Nice. > "The solution? Let's remember that metadata changes are atomic. Rename is > such a case." > Hmmm. Is he referring to th

[issue13252] new decumulate() function in itertools module

2011-10-23 Thread Petri Lehtinen
Changes by Petri Lehtinen : -- nosy: +petri.lehtinen ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe: http://mai

[issue13241] Assertion failed in _PyUnicode_CheckConsistency during build of default branch on Mac OS X

2011-10-23 Thread Ned Deily
Ned Deily added the comment: Oleg, thanks. That is consistent with previous reports; so far, this issue has only been reported with llvm-gcc, not the plain gcc-4.2's shipped in Xcode prior to 4.2. -- ___ Python tracker

[issue13253] 2to3 fix_renames renames sys.maxint only in imports

2011-10-23 Thread Ezio Melotti
New submission from Ezio Melotti : $ cat deleteme.py from sys import maxint print 'maxint', maxint $ 2to3 deleteme.py RefactoringTool: Skipping implicit fixer: buffer RefactoringTool: Skipping implicit fixer: idioms RefactoringTool: Skipping implicit fixer: set_literal RefactoringTool: Skipping

[issue13141] get rid of old threading API in the examples

2011-10-23 Thread Florent Xicluna
Changes by Florent Xicluna : -- status: open -> closed ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe: http://m

[issue13062] Introspection generator and function closure state

2011-10-23 Thread Meador Inge
Meador Inge added the comment: Nick, the revised definition of 'getclosurevars' seems reasonable to me. I will cut a new patch this week. -- ___ Python tracker ___ _

[issue11447] test_pydoc refleak

2011-10-23 Thread Antoine Pitrou
Antoine Pitrou added the comment: I can't reproduce anymore. I believe this may have been due to the fact that pydoc can try to import everything on sys.path, including third-party libraries. I got bitten by that on another issue. -- resolution: -> invalid stage: needs patch -> commi

[issue10363] Embedded python, handle (memory) leak

2011-10-23 Thread Antoine Pitrou
Changes by Antoine Pitrou : -- nosy: +pitrou versions: +Python 3.2, Python 3.3 -Python 2.7 ___ Python tracker ___ ___ Python-bugs-list

[issue6216] Raise Unicode KEEPALIVE_SIZE_LIMIT from 9 to 32?

2011-10-23 Thread Antoine Pitrou
Antoine Pitrou added the comment: Closing as outdated. There are no freelists anymore in the unicode implementation. -- resolution: -> out of date stage: -> committed/rejected status: open -> closed ___ Python tracker

[issue9239] zipfile: truncating comment can corrupt the zipfile

2011-10-23 Thread Antoine Pitrou
Changes by Antoine Pitrou : -- stage: -> patch review type: performance -> behavior versions: +Python 3.3 ___ Python tracker ___ ___ P

[issue8828] Atomic function to rename a file

2011-10-23 Thread Antoine Pitrou
Antoine Pitrou added the comment: "The solution? Let's remember that metadata changes are atomic. Rename is such a case." This is from a MSDN blog, I would hope he knows what he's talking about. http://blogs.msdn.com/b/adioltean/archive/2005/12/28/507866.aspx (MoveFileEx appears in Windows XP

[issue8828] Atomic function to rename a file

2011-10-23 Thread Antoine Pitrou
Antoine Pitrou added the comment: MoveFileTransacted is only available under Vista or later. You should be able to use MoveFileEx for the same effect. -- ___ Python tracker ___

[issue13141] get rid of old threading API in the examples

2011-10-23 Thread Antoine Pitrou
Antoine Pitrou added the comment: Should be closed, no? -- nosy: +pitrou ___ Python tracker ___ ___ Python-bugs-list mailing list Uns

[issue13228] Add "Quick Start" section to the devguide index

2011-10-23 Thread Ezio Melotti
Ezio Melotti added the comment: Done, thanks for the feedback! -- resolution: -> fixed stage: commit review -> committed/rejected status: open -> closed ___ Python tracker ___

[issue13228] Add "Quick Start" section to the devguide index

2011-10-23 Thread Roundup Robot
Roundup Robot added the comment: New changeset 25f1c003ea01 by Ezio Melotti in branch 'default': #13228: add a "Quick Start" section to the index page. http://hg.python.org/devguide/rev/25f1c003ea01 -- nosy: +python-dev ___ Python tracker

[issue13228] Add "Quick Start" section to the devguide index

2011-10-23 Thread Ezio Melotti
Ezio Melotti added the comment: That's a good point, but I find the wording a bit long. The attached patch tries to keep it short and adds a link to the section that explains when and why it's python.exe. -- Added file: http://bugs.python.org/file23509/issue13228-3.diff

[issue10332] Multiprocessing maxtasksperchild results in hang

2011-10-23 Thread Antoine Pitrou
Antoine Pitrou added the comment: The patch looks good to me, thanks. -- versions: +Python 3.3 -Python 3.1 ___ Python tracker ___ ___

[issue13215] multiprocessing Manager.connect() aggressively retries refused connections

2011-10-23 Thread Antoine Pitrou
Antoine Pitrou added the comment: I'm not sure, but I think that would be for the case where you are spawning the server yourself and the child process takes time to start up. -- nosy: +neologix, pitrou ___ Python tracker

[issue13250] ctypes: reference leak in POINTER code

2011-10-23 Thread Meador Inge
Meador Inge added the comment: Ah, I see now. Thanks Benjamin. > So it's not a bug at all, right? A bug in regrtest.py maybe. 'dash_R_cleanup' clears various other caches in between test runs to avoid false positives like this. Perhaps 'ctypes._pointer_type_cache' should be cleared there as

[issue13251] Update string description in datamodel.rst

2011-10-23 Thread Martin v . Löwis
Martin v. Löwis added the comment: LGTM. -- ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python

[issue13251] Update string description in datamodel.rst

2011-10-23 Thread Ezio Melotti
Ezio Melotti added the comment: New patch that doesn't mention surrogates, as suggested by Antoine. -- Added file: http://bugs.python.org/file23508/issue13251-2.diff ___ Python tracker

[issue13252] new decumulate() function in itertools module

2011-10-23 Thread Carlo Verre
New submission from Carlo Verre : After in Python 3.2 the accumulate() function has been added to itertools module, for self-evident reasons of completeness and symmetry we could add in 3.3 the inverse decumulate() function, which, given the iterable argument p, yields p[0], p[1] - p[0], p[2]

[issue13251] Update string description in datamodel.rst

2011-10-23 Thread Ezio Melotti
New submission from Ezio Melotti : The attached patch updates the definition of "String" after PEP 393. -- assignee: ezio.melotti components: Documentation, Unicode files: issue13251.diff keywords: needs review, patch messages: 146262 nosy: eric.araujo, ezio.melotti, haypo, lemburg, loew

[issue13250] ctypes: reference leak in POINTER code

2011-10-23 Thread Martin v . Löwis
Martin v. Löwis added the comment: So it's not a bug at all, right? -- nosy: +loewis resolution: -> invalid status: open -> closed ___ Python tracker ___ __

[issue13243] _Py_identifier should be _Py_IDENTIFER

2011-10-23 Thread Martin v . Löwis
Martin v. Löwis added the comment: Am 23.10.2011 20:33, schrieb Meador Inge: > > Meador Inge added the comment: > >> Most definitely not. It is very deliberate that asdl_c.py is only >> invoked when the ASDL sources change. Otherwise, having Python installed >> would be a build requirement fo

[issue13248] deprecated in 3.2, should be removed in 3.3

2011-10-23 Thread Ezio Melotti
Ezio Melotti added the comment: *unittest* "assert{DictContainsSubset,RaisesRegexp,RegexpMatches}", "fail*" The "fail*" should stay. The general idea is that with Python3 we can wait a bit more before getting rid of things, because if someone jumps from 2.7 to 3.3, he might not find things

[issue13249] argparse.ArgumentParser() lists arguments in the wrong order

2011-10-23 Thread Roy Smith
Roy Smith added the comment: PS -- this is against the 2.7 branch. -- ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubs

[issue13249] argparse.ArgumentParser() lists arguments in the wrong order

2011-10-23 Thread Roy Smith
Roy Smith added the comment: Patch attached. I just deal with putting all the items into the same order, not terry.reedy's idea for separating them into two groups. Added a recommendation to only use keywords, which seems sane given the number of arguments. -- keywords: +patch Added

[issue13141] get rid of old threading API in the examples

2011-10-23 Thread Florent Xicluna
Changes by Florent Xicluna : -- resolution: -> fixed stage: patch review -> committed/rejected ___ Python tracker ___ ___ Python-bugs

[issue13141] get rid of old threading API in the examples

2011-10-23 Thread Roundup Robot
Roundup Robot added the comment: New changeset 8de472fb8cfe by Florent Xicluna in branch '2.7': Issue #13141: Demonstrate recommended style for SocketServer examples. http://hg.python.org/cpython/rev/8de472fb8cfe -- ___ Python tracker

[issue13141] get rid of old threading API in the examples

2011-10-23 Thread Roundup Robot
Roundup Robot added the comment: New changeset d34beaaf7060 by Florent Xicluna in branch '3.2': Issue 13141: Demonstrate recommended style for socketserver examples. http://hg.python.org/cpython/rev/d34beaaf7060 -- nosy: +python-dev ___ Python tracke

[issue13249] argparse.ArgumentParser() lists arguments in the wrong order

2011-10-23 Thread Roy Smith
Roy Smith added the comment: I'm working on a doc patch now... -- ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscrib

[issue12965] longobject: documentation improvements

2011-10-23 Thread Mark Dickinson
Mark Dickinson added the comment: > It could be fun to remove these conversions and see how much of the > test-suite fails. :-) ... On my machine, just test_ctypes and test_getargs2, as it turns out. -- ___ Python tracker

[issue12965] longobject: documentation improvements

2011-10-23 Thread Mark Dickinson
Mark Dickinson added the comment: I've fixed some of the inaccurate comments in Objects/longobject.c, for the default branch; I'm still looking at the Doc update. This really is a bit of a mess, especially for cases like PyLong_AsVoidPtr, which can either end up calling PyLong_As(Long)Long (

[issue12965] longobject: documentation improvements

2011-10-23 Thread Roundup Robot
Roundup Robot added the comment: New changeset d4839fea4a5a by Mark Dickinson in branch 'default': Issue #12965: Fix some inaccurate comments in Objects/longobject.c. Thanks Stefan Krah. http://hg.python.org/cpython/rev/d4839fea4a5a -- nosy: +python-dev __

[issue13249] argparse.ArgumentParser() lists arguments in the wrong order

2011-10-23 Thread Roy Smith
Roy Smith added the comment: An Nth place is in the docstring: Keyword Arguments: - prog -- The name of the program (default: sys.argv[0]) - usage -- A usage m

[issue9980] str(float) failure

2011-10-23 Thread Mark Dickinson
Mark Dickinson added the comment: Closing as "won't fix", for reasons given above. -- resolution: -> wont fix status: open -> closed ___ Python tracker ___ _

[issue13249] argparse.ArgumentParser() lists arguments in the wrong order

2011-10-23 Thread Terry J. Reedy
Terry J. Reedy added the comment: In the doc, the signature line is followed by a list of short descriptions in a third order. That perhaps should be changed to follow the same corrected order as the signature line. On the other hand, it matches the order of the detail sections that follow. O

[issue10925] Document pure Python version of integer-to-float correctly-rounded conversion

2011-10-23 Thread Mark Dickinson
Changes by Mark Dickinson : -- resolution: -> fixed stage: -> committed/rejected status: open -> closed ___ Python tracker ___ ___ P

[issue10925] Document pure Python version of integer-to-float correctly-rounded conversion

2011-10-23 Thread Roundup Robot
Roundup Robot added the comment: New changeset 117d51d3dd7d by Mark Dickinson in branch 'default': Issue #10925: Add equivalent pure Python code for the builtin int-to-float conversion to test_long. http://hg.python.org/cpython/rev/117d51d3dd7d -- nosy: +python-dev ___

[issue13249] argparse.ArgumentParser() lists arguments in the wrong order

2011-10-23 Thread Santoso Wijaya
Changes by Santoso Wijaya : -- nosy: +santa4nt ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.pyth

[issue13249] argparse.ArgumentParser() lists arguments in the wrong order

2011-10-23 Thread Petri Lehtinen
Petri Lehtinen added the comment: Fixing the documentation is better, as changing the argument order would break existing code. -- keywords: +easy nosy: +petri.lehtinen ___ Python tracker

[issue13201] Implement comparison operators for range objects

2011-10-23 Thread Roundup Robot
Roundup Robot added the comment: New changeset 479a7dd1ea6a by Mark Dickinson in branch 'default': Issue #13201: equality for range objects is now based on equality of the underlying sequences. Thanks Sven Marnach for the patch. http://hg.python.org/cpython/rev/479a7dd1ea6a -- nosy: +

[issue13201] Implement comparison operators for range objects

2011-10-23 Thread Mark Dickinson
Changes by Mark Dickinson : -- resolution: -> fixed stage: commit review -> committed/rejected status: open -> closed ___ Python tracker ___

[issue13201] Implement comparison operators for range objects

2011-10-23 Thread Mark Dickinson
Mark Dickinson added the comment: > In most cases, global variables Py_Zero and Py_One would be enough to > simplify this kind of code. Agreed. -- ___ Python tracker ___ __

[issue13250] ctypes: reference leak in POINTER code

2011-10-23 Thread Benjamin Peterson
Benjamin Peterson added the comment: The cause is ctypes caches POINTER types. You have to make sure to clear the cache. -- nosy: +benjamin.peterson ___ Python tracker ___

[issue13250] ctypes: reference leak in POINTER code

2011-10-23 Thread Meador Inge
New submission from Meador Inge : While implementing a patch for issue13096 I found a reference leak in 'ctypes'. I couldn't find the cause immediately, but it can be reproduced by applying the attached patch and running: [meadori@motherbrain cpython]$ ./python -m test -R : test_ctypes [1/1]

[issue13249] argparse.ArgumentParser() lists arguments in the wrong order

2011-10-23 Thread Florent Xicluna
Florent Xicluna added the comment: in 3.x, same issue. IMHO documentation should be fixed. -- assignee: -> docs@python components: +Documentation nosy: +bethard, docs@python, flox stage: -> needs patch versions: +Python 3.2, Python 3.3 ___ Python t

[issue13241] Assertion failed in _PyUnicode_CheckConsistency during build of default branch on Mac OS X

2011-10-23 Thread STINNER Victor
STINNER Victor added the comment: > i686-apple-darwin10-llvm-gcc-4.2 (GCC) 4.2.1 (Based on Apple Inc. build 5658) > (LLVM build 2336.1.00) Oh, that's not GCC but llvm-gcc. It is maybe a bug in LLVM? -- ___ Python tracker

[issue13249] argparse.ArgumentParser() lists arguments in the wrong order

2011-10-23 Thread Roy Smith
New submission from Roy Smith : The docs list the arguments in the order: class argparse.ArgumentParser([description][, epilog][, prog]... but the code (I'm looking at the 2.7.2 source) lists them as: class ArgumentParser(_AttributeHolder, _ActionsContainer): [...] def __init__(self,

[issue13243] _Py_identifier should be _Py_IDENTIFER

2011-10-23 Thread Meador Inge
Meador Inge added the comment: > Most definitely not. It is very deliberate that asdl_c.py is only > invoked when the ASDL sources change. Otherwise, having Python installed > would be a build requirement for Python, which it must be not. OK, thanks for the background. To be clear, though, the

[issue13248] deprecated in 3.2, should be removed in 3.3

2011-10-23 Thread Florent Xicluna
Florent Xicluna added the comment: In addition, we have some object and attributes which are triggering "PendingDeprecationWarning" in 3.2. We may keep these warnings in 3.3, or choose to turn some of them into "DeprecationWarning", to prepare their removal in 3.5. *cgi* "cgi.escape" *dist

[issue13248] deprecated in 3.2, should be removed in 3.3

2011-10-23 Thread Florent Xicluna
New submission from Florent Xicluna : The PEP 387 suggests that deprecated objects or arguments are removed in version (n+1). I've listed these DeprecationWarnings in 3.2, which are still in 3.3. I assume that most of these deprecated objects or arguments could be removed before next release.

[issue13240] sysconfig gives misleading results for USE_COMPUTED_GOTOS

2011-10-23 Thread Meador Inge
Meador Inge added the comment: > Actually, I think sysconfig does the right thing when it comes to all > the configure-generated HAVE_XXX variables I agree. The 'configure' script could be improved, though. If we truly want to enable this by default, then the defaulting should be moved to con

[issue13241] Assertion failed in _PyUnicode_CheckConsistency during build of default branch on Mac OS X

2011-10-23 Thread Oleg Plakhotnyuk
Oleg Plakhotnyuk added the comment: Ah, of course. Initially I've tried to compile using this: i686-apple-darwin10-llvm-gcc-4.2 (GCC) 4.2.1 (Based on Apple Inc. build 5658) (LLVM build 2336.1.00) XCode version 4.2, build 4C199 -- ___ Python tracke

[issue13241] Assertion failed in _PyUnicode_CheckConsistency during build of default branch on Mac OS X

2011-10-23 Thread Ned Deily
Ned Deily added the comment: In general, I would not recommend using anything other than an Apple-supplied tool chain for building anything on Mac OS X. To help us better understand the issues, can you say exactly which compilers you tried originally, i.e. the complete --version output from

[issue1294232] Error in metaclass search order

2011-10-23 Thread Nick Coghlan
Nick Coghlan added the comment: Fix has been applied to 3.x and hence will be in 3.3 and the next 3.2 release. I have adjusted the issue metadata to reflect the fact 2,7 still exhibits the problem, but the patch requires significant work to account for the 3.x vs 2.x changes in class creation

[issue13246] Py_UCS4_strlen and friends needn't be public

2011-10-23 Thread Georg Brandl
Georg Brandl added the comment: Making sure we don't forget that :) -- priority: normal -> release blocker ___ Python tracker ___ ___

[issue1294232] Error in metaclass search order

2011-10-23 Thread Roundup Robot
Roundup Robot added the comment: New changeset c2a89b509be4 by Nick Coghlan in branch '3.2': Issue 1294232: Fix errors in metaclass calculation affecting some cases of metaclass inheritance. Patch by Daniel Urban. http://hg.python.org/cpython/rev/c2a89b509be4 New changeset c72063032a7a by Nick

[issue13246] Py_UCS4_strlen and friends needn't be public

2011-10-23 Thread Martin v . Löwis
Martin v. Löwis added the comment: Before the release, we should consider whether we can drop these functions altogether. -- ___ Python tracker ___

[issue13243] _Py_identifier should be _Py_IDENTIFER

2011-10-23 Thread Martin v . Löwis
Martin v. Löwis added the comment: > Maybe we should change the build system to always regenerate the files > or add something to automation that regenerates the AST C file every > time. Most definitely not. It is very deliberate that asdl_c.py is only invoked when the ASDL sources change. Othe

[issue13217] Missing header dependencies in Makefile

2011-10-23 Thread Petri Lehtinen
Changes by Petri Lehtinen : -- nosy: +petri.lehtinen ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe: http://mai

[issue13140] ThreadingMixIn.daemon_threads is not honored when parent is daemon

2011-10-23 Thread Charles-François Natali
Charles-François Natali added the comment: > I would prefer to preserve the inheritance by default, and to change the > daemonic attribute only if it is explicitly set to True or False. > This way it will be backward compatible. It may be backward compatible, but IMHO, the current behavior is

[issue8828] Atomic function to rename a file

2011-10-23 Thread Charles-François Natali
Charles-François Natali added the comment: The recent issue #13146 renewed my interest, so I'd like to make this move forward, since I think an atomic rename/write API could be quite useful. Issue #8604 (Adding an atomic FS write API) can be achieved relatively easily with the typical (fsync()

[issue13105] Please elaborate on how 2.x and 3.x are different heads

2011-10-23 Thread Nick Coghlan
Nick Coghlan added the comment: The devguide actually did align with what I said in my email, but this wasn't clear if you only read the "Forward Porting" section (you had to read the "Porting Between Major Versions" section further down the page as well). I added a new paragraph to the forwa

[issue13105] Please elaborate on how 2.x and 3.x are different heads

2011-10-23 Thread Roundup Robot
Roundup Robot added the comment: New changeset 0541f815d016 by Nick Coghlan in branch 'default': Update NEWS entry policy based on recent mailing list discussion and forward porting section based on Issue 13105 http://hg.python.org/devguide/rev/0541f815d016 -- nosy: +python-dev __

[issue13241] Assertion failed in _PyUnicode_CheckConsistency during build of default branch on Mac OS X

2011-10-23 Thread Oleg Plakhotnyuk
Changes by Oleg Plakhotnyuk : -- status: open -> pending ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe: http:/

[issue13241] Assertion failed in _PyUnicode_CheckConsistency during build of default branch on Mac OS X

2011-10-23 Thread Oleg Plakhotnyuk
Changes by Oleg Plakhotnyuk : -- resolution: works for me -> fixed status: pending -> open ___ Python tracker ___ ___ Python-bugs-list

[issue13241] Assertion failed in _PyUnicode_CheckConsistency during build of default branch on Mac OS X

2011-10-23 Thread Oleg Plakhotnyuk
Changes by Oleg Plakhotnyuk : -- status: open -> pending ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe: http:/

[issue13241] Assertion failed in _PyUnicode_CheckConsistency during build of default branch on Mac OS X

2011-10-23 Thread Oleg Plakhotnyuk
Changes by Oleg Plakhotnyuk : -- resolution: -> works for me ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe: h

[issue13241] Assertion failed in _PyUnicode_CheckConsistency during build of default branch on Mac OS X

2011-10-23 Thread Oleg Plakhotnyuk
Oleg Plakhotnyuk added the comment: Thank you all for help. I finally managed to build it. :-) So here are complete steps I've taken to build python after OS reinstall: 1. Install XCode 4.2 2. Install MacPorts 3. sudo port -v selfupdate 4. sudo port install gcc46 5. ./configure CC=gcc-mp-4.6 LDF

[issue13247] os.path.abspath returns unicode paths as question marks

2011-10-23 Thread STINNER Victor
STINNER Victor added the comment: abspath() is implemented using nt._getfullpathname() which calls GetFullPathNameA(). > The returned path with question marks is completely useless. Can you open the file using such filename? If no, I agree that the result is useless. > It's better that pyth

[issue13246] Py_UCS4_strlen and friends needn't be public

2011-10-23 Thread STINNER Victor
STINNER Victor added the comment: > It seems there's no reason to document these functions > which operate on null-terminated unicode arrays. It's the easiest way to create a new string with the new Unicode API, when it's difficult to predict the exact output length and maximum character: Py_