[issue4755] Add function to get common path prefix
Changes by anatoly techtonik techto...@gmail.com: -- nosy: +techtonik ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue4755 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue14884] Windows Build instruction typo
Changes by Eli Bendersky eli...@gmail.com: -- nosy: +eli.bendersky ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue14884 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue14886] json C vs pure-python implementation difference
New submission from Марк Коренберг socketp...@gmail.com: Pure-python implementation: if isinstance(o, (list, tuple)): C implementation: if (PyList_Check(obj) || PyTuple_Check(obj)) This make real difference (!) in my code. So, please change pure-python implementation to: if type(o) in (list, tuple): Or, fix C implementation to: /* intentionally forgot (only for this example) to check if return value is -1 */ if (PyObject_IsInstance(obj, PyList_Type) || PyObject_IsInstance(obj, PyTuple_Type) -- components: Library (Lib) messages: 161395 nosy: mmarkk priority: normal severity: normal status: open title: json C vs pure-python implementation difference versions: Python 2.7, Python 3.1, Python 3.2, Python 3.3, Python 3.4 ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue14886 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue14886] json C vs pure-python implementation difference
Changes by Марк Коренберг socketp...@gmail.com: -- type: - behavior ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue14886 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue14887] pysetup: unfriendly error message for unknown commands
New submission from Ronald Oussoren ronaldousso...@mac.com: The pysetup3 command gives a fairly unfriendly error message with python traceback when you specify an unknown command: pysetup3 instal Unrecognized action instal Traceback (most recent call last): File /Library/Frameworks/PythonDev.framework/Versions/3.3/lib/python3.3/packaging/run.py, line 647, in main dispatcher = Dispatcher(args) File /Library/Frameworks/PythonDev.framework/Versions/3.3/lib/python3.3/packaging/run.py, line 401, in __init__ raise PackagingArgError(msg) packaging.errors.PackagingArgError: Unrecognized action instal The traceback is not useful for the user of the script and should therefore not be shown. BTW. It would also be nice if 'pysetup3 help' would give the same output as 'pysetup3 --help', similar to how 'hg help' behaves. -- assignee: eric.araujo components: Distutils2 messages: 161396 nosy: alexis, eric.araujo, ronaldoussoren, tarek priority: low severity: normal stage: needs patch status: open title: pysetup: unfriendly error message for unknown commands type: behavior versions: Python 3.3 ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue14887 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue14885] shutil tests, test_copy2_xattr and test_copyxattr, fail
Roundup Robot devn...@psf.upfronthosting.co.za added the comment: New changeset ab94ed2a8012 by Hynek Schlawack in branch 'default': #14885: Make support.skip_unless_xattr check also tempfile http://hg.python.org/cpython/rev/ab94ed2a8012 -- nosy: +python-dev ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue14885 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue14885] shutil tests, test_copy2_xattr and test_copyxattr, fail
Hynek Schlawack h...@ox.cx added the comment: Awesome, thank you for your cooperation! -- resolution: - fixed stage: - committed/rejected status: open - closed ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue14885 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue14886] json C vs pure-python implementation difference
Changes by Chris Rebert pyb...@rebertia.com: -- nosy: +cvrebert ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue14886 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue14886] json C vs pure-python implementation difference
Antoine Pitrou pit...@free.fr added the comment: What difference does it make? Are you using __instancecheck__ perhaps? -- nosy: +pitrou versions: -Python 3.1, Python 3.4 ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue14886 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue1191964] asynchronous Subprocess
Ross Lagerwall rosslagerw...@gmail.com added the comment: Personally, I would factor out the code for Popen.communicate() in to a Communicator class which wraps a Popen object and has a method communicate(input, timeout=None) - (bytes_written, output, error) How would this differ from the normal communicate()? It seems like there are two different ideas for why people want an asynchronous subprocess: One is that they want to use communicate() but not be limited by memory issues. I think a good API for this case is an asyncore style API or like the one from the patch in issue1260171. Another use case is for an expect-type interface where you read and write based on a timeout or some kind of delimiter like a newline. These should probably be addressed independently. See also issue10482. -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue1191964 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue14884] Windows Build instruction typo
Michael Driscoll m...@pythonlibrary.org added the comment: Here's a new patch that I think addresses both issues. Thanks for your insights. -- Added file: http://bugs.python.org/file25678/setup.patch ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue14884 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue12271] Python 2.7.x on IA64 running SLES 11 SP1
Holger Mickler holger.mick...@tu-dresden.de added the comment: I just stumbled upon the same problem with Python 2.7.3 on SLES 11 SP1 amd64. Obviously, SuSE puts the needed header file into /usr/include/ncurses/, and one can either create a symlink in /usr/include/ or apply a patch to _curses_panel.c: --- Modules/_curses_panel.c.orig2012-05-23 13:34:17.0 +0200 +++ Modules/_curses_panel.c 2012-05-23 13:34:27.0 +0200 @@ -14,7 +14,7 @@ #include py_curses.h -#include panel.h +#include ncurses/panel.h static PyObject *PyCursesError; Maybe some logic could be put into the build process to automatically handle this? Apparently, configure already knows about the different locations... Regards, Holger -- nosy: +hm ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue12271 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue12014] str.format parses replacement field incorrectly
Petri Lehtinen pe...@digip.org added the comment: Ben Wolfson wrote: Maybe, but the last time it went to python-dev (in December) there was little discussion at all, and the patches that exist now worked on the codebase as it existed then. Maybe it's pointless to bring it up on python-dev then. I just thought that people might feel strongly about this. Anyway, it seems as if progress is being made on PEP 420, so perhaps better to let Eric take a look before bringing it up again? Let's wait for Eric's comments, as he implemented format() in the first place. -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue12014 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue14879] invalid docs for subprocess exceptions with shell=True
R. David Murray rdmur...@bitdance.com added the comment: Heh. Maybe what we ought to do is drop the shell argument and make everyone build their own shell invocations :) Actually, an API refactor where a shell call looks like this might be kind of cool: Popen(shell_cmd('echo magic')) where shell would return a list. As for the ValueError, yeah, it's vague, but I think that the only information that sentence is trying to convey is that ValueError is one of the exceptions you might get when calling Popen. Exactly what you get it for is pretty much an implementation detail. If someone wants to grovel through the code and figure out all the things that can raise ValueError, we could see if there's any sensible way to turn that into a sentence, but it might not be easy. Short of that, perhaps we could drop the existing qualifier and just say Popen may also raise ValueError. -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue14879 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue6721] Locks in python standard library should be sanitized on fork
Richard Oudkerk shibt...@gmail.com added the comment: (1) Good catch. I suspect that this could be mitigated even if we cared about LinuxThreads. I haven't looked, but there's got to be a way to determine if we are a thread or a fork child. Using a generation count would probably work just as well as the PID: main process has generation 0, children have generation 1, grandchildren have generation 2, ... (2) I think I didn't explain my idea very well. I don't mean that we should release *all* locks on fork. That will end in disaster, as Charles-François amply explained. So what are you suggesting? That a lock of the default type should raise an error if you try to acquire it when it has been acquired in a previous process? -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue6721 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue12271] Python 2.7.x on IA64 running SLES 11 SP1
Changes by Antoine Pitrou pit...@free.fr: -- resolution: invalid - stage: committed/rejected - versions: +Python 3.2, Python 3.3 ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue12271 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue14888] _md5 module crashes on large data
New submission from Antoine Pitrou pit...@free.fr: This appears to be 2.7-only: $ ./python -m test.regrtest -M5G -v test_hashlib == CPython 2.7.3+ (2.7:086afe7b61f5, May 23 2012, 15:15:34) [GCC 4.5.2] == Linux-2.6.38.8-desktop-10.mga-x86_64-with-mandrake-1-Official little-endian == /home/antoine/cpython/27/build/test_python_6042 Testing with flags: sys.flags(debug=0, py3k_warning=0, division_warning=0, division_new=0, inspect=0, interactive=0, optimize=0, dont_write_bytecode=0, no_user_site=0, no_site=0, ignore_environment=0, tabcheck=0, verbose=0, unicode=0, bytes_warning=0, hash_randomization=0) test_hashlib test_algorithms_attribute (test.test_hashlib.HashLibTestCase) ... ok test_case_md5_0 (test.test_hashlib.HashLibTestCase) ... ok test_case_md5_1 (test.test_hashlib.HashLibTestCase) ... ok test_case_md5_2 (test.test_hashlib.HashLibTestCase) ... ok test_case_md5_huge (test.test_hashlib.HashLibTestCase) ... python: /home/antoine/cpython/27/Modules/md5module.c:276: MD5_new: Assertion `(Py_ssize_t)(unsigned int)(view.len) == (view.len)' failed. Abandon -- components: Extension Modules messages: 161406 nosy: gregory.p.smith, pitrou priority: low severity: normal stage: needs patch status: open title: _md5 module crashes on large data type: crash versions: Python 2.7 ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue14888 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue14888] _md5 module crashes on large data
Antoine Pitrou pit...@free.fr added the comment: Here is a patch. -- keywords: +patch Added file: http://bugs.python.org/file25679/md5_huge.patch ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue14888 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue14888] _md5 module crashes on large data
Changes by Antoine Pitrou pit...@free.fr: -- stage: needs patch - patch review ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue14888 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue14855] IPv6 support for logging.handlers
Yuriy Syrovetskiy c...@cblp.su added the comment: Can the datagramHandler.host change during execution? If so, the address family of the socket can change. So, we should create a socket for every new message. Check my patch #2. Also I extended socket.create_connection to support UDP. -- Added file: http://bugs.python.org/file25680/mywork2.patch ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue14855 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue1191964] asynchronous Subprocess
Richard Oudkerk shibt...@gmail.com added the comment: How would this differ from the normal communicate()? It would block until one of the following occurs: * some data has been written to stdin, * some data has been read from stdout or stderr, or * timeout passes (if timeout is not None). The normal communicate() could be implemented by running this in a loop. The amount of data returned at once could be limited by an argument of the constructor. -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue1191964 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue14855] IPv6 support for logging.handlers
Yuriy Syrovetskiy c...@cblp.su added the comment: test_logging is not broken, but just fails. test test_logging failed -- Traceback (most recent call last): File /home/cblp/my/cpython_default/Lib/test/test_logging.py, line 2903, in test_time self.assertEqual(f.formatTime(r), '1993-04-21 08:03:00,123') AssertionError: '1993-04-21 09:03:00,123' != '1993-04-21 08:03:00,123' - 1993-04-21 09:03:00,123 ? ^ + 1993-04-21 08:03:00,123 ? ^ Or should it go to the separate ticket? -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue14855 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue14888] _md5 module crashes on large data
Jesús Cea Avión j...@jcea.es added the comment: Does this affect other hash modules?. Why is this not affecting python 3? Patch looks good. -- nosy: +jcea ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue14888 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue14888] _md5 module crashes on large data
Antoine Pitrou pit...@free.fr added the comment: Does this affect other hash modules? I don't know, only md5 seems to have tests for large data. . Why is this not affecting python 3? The _md5 module was apparently rewritten in Python 3. -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue14888 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue14887] pysetup: unfriendly error message for unknown commands
Éric Araujo mer...@netwok.org added the comment: Already reported, fixed in distutils2 and to be sideported to packaging soon. -- resolution: - duplicate stage: needs patch - committed/rejected status: open - closed superseder: - Don't print traceback for unrecognized actions, commands and options in packaging ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue14887 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue14889] PyBytes_FromObject(bytes_object) fails
New submission from Larry Hastings la...@hastings.org: If you pass a valid PyUnicodeObject into PyUnicode_AsObject(), it incref's the original object and returns it. If you pass a valid PyBytesObject into PyBytes_AsObject()... it fails. I assert that in the PyBytes_AsObject() should behave like PyUnicode_AsObject() when faced with an identity transformation. (Brett: I tagged you because I saw your name in the comments, so I figured you were a good candidate.) -- assignee: larry messages: 161414 nosy: brett.cannon, larry priority: normal severity: normal stage: needs patch status: open title: PyBytes_FromObject(bytes_object) fails type: behavior versions: Python 3.3 ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue14889 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue14889] PyBytes_FromObject(bytes_object) fails
Changes by Hynek Schlawack h...@ox.cx: -- nosy: +hynek ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue14889 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue14884] Windows Build instruction typo
Eli Bendersky eli...@gmail.com added the comment: Nitpicking: the drop down (in both VC++ 2008 2010 express) is named Solution Configurations [note the 's' in the end] But this name does now appear anywhere - only if you hover on the dropbox. I don't mind either way - either leave it what it was, or change build to Solution Configurations, but do spell it correctly :) -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue14884 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue14884] Windows Build instruction typo
Michael Driscoll m...@pythonlibrary.org added the comment: @ Eli - Sorry about that. I just went with Brian's wording on that. I didn't realize it was plural. My experience with Visual Studio is limited, although I hope to rectify that at some point. Anyway, I corrected the patch and attached it. Thanks! -- Added file: http://bugs.python.org/file25681/setup.patch ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue14884 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue14884] Windows Build instruction typo
Eli Bendersky eli...@gmail.com added the comment: LGTM. Brian, any objections to commit? P.S. Michael: I usually like numbering successive versions of a patch (like setup.1.patch, setup.2.patch, or a similar scheme) - this makes it easier to refer to more than one version in a discussion without getting confused. This is just a tip for future patches. -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue14884 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue14889] PyBytes_FromObject(bytes_object) fails
Larry Hastings la...@hastings.org added the comment: The appropriate four line patch. (Six with whitespace.) -- keywords: +patch stage: needs patch - patch review Added file: http://bugs.python.org/file25682/larry.pybytes_fromobject.identity.1.diff ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue14889 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue14884] Windows Build instruction typo
Brian Curtin br...@python.org added the comment: Looks good to me. Feel free to commit it, Eli. -- assignee: brian.curtin - ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue14884 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue14889] PyBytes_FromObject(bytes_object) fails
Amaury Forgeot d'Arc amaur...@gmail.com added the comment: I suppose you are referring to PyUnicode_FromObject() and PyBytes_FromObject()... And by it fails did you simply mean it fails to return the same object? -- nosy: +amaury.forgeotdarc ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue14889 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue14889] PyBytes_FromObject(bytes_object) fails
Larry Hastings la...@hastings.org added the comment: 1) Yes, whoopsies. It's late. 2) It fails, as in, it returns NULL. -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue14889 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue14775] Dict untracking can result in quadratic dict build-up
stw sil...@googlemail.com added the comment: I had a thought about untracking tuples. If a tuple contains only immutable objects (atomics and tuples of atomics etc), then it should be untracked. Once untracked, it will never need to be tracked again since the tuple is immutable. If a tuple contains mutable objects, it will always need to be tracked. I was wondering whether it is possible to determine whether a tuple needs to be tracked or not the first time it appears in generation 0 - tuples in older generations would then not need to be considered. -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue14775 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue14889] PyBytes_FromObject(bytes_object) fails
Amaury Forgeot d'Arc amaur...@gmail.com added the comment: 2) It fails, as in, it returns NULL. It's not my experience. Do you have an example? -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue14889 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue14889] PyBytes_FromObject(bytes_object) fails
Antoine Pitrou pit...@free.fr added the comment: Well, the patch is nice but the PyObject_CheckBuffer(...) part should have succeeded, so it's a bit mysterious why it doesn't. -- nosy: +pitrou ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue14889 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue14775] Dict untracking can result in quadratic dict build-up
Antoine Pitrou pit...@free.fr added the comment: I had a thought about untracking tuples. If a tuple contains only immutable objects (atomics and tuples of atomics etc), then it should be untracked. Once untracked, it will never need to be tracked again since the tuple is immutable. If a tuple contains mutable objects, it will always need to be tracked. True. However, some tuples may be in an unfinished state (they are being built up internally and a GC collection occurred in the middle). I was wondering whether it is possible to determine whether a tuple needs to be tracked or not the first time it appears in generation 0 - tuples in older generations would then not need to be considered. I'm not sure that would make much of a difference in practice. Most tuples are very short, so checking them for untracking should be reasonably fast. -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue14775 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue14888] _md5 module crashes on large data
Antoine Pitrou pit...@free.fr added the comment: I can't reproduce this issue in my 64 bit machines, neither in Solaris neither in Ubuntu. I guess the assertion can be fooled by compiler optimizacions. You should compile in debug mode. -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue14888 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue14888] _md5 module crashes on large data
Jesús Cea Avión j...@jcea.es added the comment: I can't reproduce this issue in my 64 bit machines, neither in Solaris neither in Ubuntu. I guess the assertion can be fooled by compiler optimizacions. As a consequence, I can't check other hashes functions. Antoine, can you reproduce it doing md5.new(A*(2**32+5)).hexdigest()?. That is what test HUGE does. -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue14888 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue14885] shutil tests, test_copy2_xattr and test_copyxattr, fail
Éric Araujo mer...@netwok.org added the comment: FTR a few of us would prefer to kill TESTFN and use only tempfile in tests. It’s cleaner. -- nosy: +eric.araujo ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue14885 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue14889] PyBytes_FromObject(bytes_object) fails
Changes by Jesús Cea Avión j...@jcea.es: -- nosy: +jcea ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue14889 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue14890] typo in difflib
Changes by ninsen jcsla...@gmail.com: -- components: Library (Lib) files: mywork.patch keywords: patch nosy: ninsen priority: normal severity: normal status: open title: typo in difflib type: behavior versions: Python 2.7 Added file: http://bugs.python.org/file25683/mywork.patch ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue14890 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue14890] typo in difflib
Changes by ninsen jcsla...@gmail.com: -- type: behavior - ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue14890 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue14884] Windows Build instruction typo
Michael Driscoll m...@pythonlibrary.org added the comment: Thanks for the tip Eli. I'll try to remember to number my patches next time. This is my first time doing this. -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue14884 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue14890] typo in difflib
New submission from ninsen jcsla...@gmail.com: This is my first patch. -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue14890 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue14885] shutil tests, test_copy2_xattr and test_copyxattr, fail
Hynek Schlawack h...@ox.cx added the comment: It _does_ seem to me like cruft. Ditching it won’t be easy though: $ grep -PR TESTFN Lib/test | wc -l 1390 But it’s good to know to actively avoid using TESTFN whenever possible. I usually adapted myself to module style till now. -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue14885 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue14891] An error in bindings of closures
New submission from Frederick Ross madhad...@gmail.com: The following code throws an UnboundLocal error: def f(x): def g(): x = x + a return x return g() f(b) -- components: None messages: 161432 nosy: Frederick.Ross priority: normal severity: normal status: open title: An error in bindings of closures type: behavior versions: Python 2.7 ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue14891 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue14890] typo in difflib
Hynek Schlawack h...@ox.cx added the comment: Hmmm, iff could be also meant as a abbreviation for “if and only if: http://en.wikipedia.org/wiki/Iff IIRC is the usage of such abbreviations rather frowned upon though. -- nosy: +hynek ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue14890 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue14775] Dict untracking can result in quadratic dict build-up
stw sil...@googlemail.com added the comment: I had a thought about untracking tuples. If a tuple contains only immutable objects (atomics and tuples of atomics etc), then it should be untracked. Once untracked, it will never need to be tracked again since the tuple is immutable. If a tuple contains mutable objects, it will always need to be tracked. True. However, some tuples may be in an unfinished state (they are being built up internally and a GC collection occurred in the middle). So the tuple is linked-in to the garbage collection list before its contents are constructed? I was wondering whether it is possible to determine whether a tuple needs to be tracked or not the first time it appears in generation 0 - tuples in older generations would then not need to be considered. I'm not sure that would make much of a difference in practice. Most tuples are very short, so checking them for untracking should be reasonably fast. Could tuples not be untracked at creation time then, or do not enough survive to gc to make this worthwhile? -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue14775 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue14890] typo in difflib
Ross Lagerwall rosslagerw...@gmail.com added the comment: Yeah, I'm pretty sure it means if and only if. -- nosy: +rosslagerwall ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue14890 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue14775] Dict untracking can result in quadratic dict build-up
Antoine Pitrou pit...@free.fr added the comment: Le mercredi 23 mai 2012 à 16:22 +, stw a écrit : So the tuple is linked-in to the garbage collection list before its contents are constructed? It is. It typically happens when you do (in C code): PyObject *my_tuple = PyTuple_New(2); /* compute some_object ... */ PyTuple_SET_ITEM(my_tuple, 0, some_object); /* compute some_other_object ... */ PyTuple_SET_ITEM(my_tuple, 1, some_other_object); Could tuples not be untracked at creation time then, or do not enough survive to gc to make this worthwhile? The latter. Also, tuples are created at a high rate in the interpreter, so it can actually decrease performance. -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue14775 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue14891] An error in bindings of closures
Amaury Forgeot d'Arc amaur...@gmail.com added the comment: This is expected behavior: http://docs.python.org/faq/programming.html#why-am-i-getting-an-unboundlocalerror-when-the-variable-has-a-value -- nosy: +amaury.forgeotdarc resolution: - invalid status: open - closed ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue14891 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue14888] _md5 module crashes on large data
Jesús Cea Avión j...@jcea.es added the comment: sha1 fails the same way. Same error. Just clone the test to show it. Please, correct sha1 too and add a test for it :). sha224, sha256, sha384 and sha512 seems OK. -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue14888 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue14888] _md5 module crashes on large data
Jesús Cea Avión j...@jcea.es added the comment: sha224, sha256, sha384 and sha512 are not failing because they are missing the Py_SAFE_DOWNCAST safety net completely. So I would tell that we have an issue here :). -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue14888 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue14888] _md5 module crashes on large data
Jesús Cea Avión j...@jcea.es added the comment: Same can be said about Python 3 hash modules: they are not using the sanity check, so they work. Maybe the real question should be if the sanity check really makes sense at all. If not, remove everywhere (the calculated md5 with no checks looks correct, after all). If it makes sense, mark this as python 3.2 and 3.3 and patch everywhere :). Do you agree, Antoine? -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue14888 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue14888] _md5 module crashes on large data
Antoine Pitrou pit...@free.fr added the comment: sha1 fails the same way. Same error. Just clone the test to show it. Please, correct sha1 too and add a test for it :). Well, do you want to provide an updated patch? -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue14888 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue14891] An error in bindings of closures
Frederick Ross madhad...@gmail.com added the comment: Assignment in Python creates a new binding. Whether the new binding shadows or replaces an old binding should be irrelevant. This behavior is inconsistent with that. Please fix expectations, and then Python interpreter. -- resolution: invalid - status: closed - open ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue14891 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue14668] Document the path option in the Windows installer
Michael Driscoll m...@pythonlibrary.org added the comment: Looking at 3.3.rst, it looks like we could just add the blurb to the end of the file in the Other issues section. The windows.rst file is potentially more complicated as I assume we need to leave the directions for adding the path for users that are using older versions of Python. Perhaps we could add a sentence to the effect of: As of Python 3.3, you may add Python and its Scripts directory to your PATH environment variable during installation of Python. -- nosy: +michael.driscoll ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue14668 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue13445] Enable linking the module pysqlite with Berkeley DB SQL instead of SQLite
Petri Lehtinen pe...@digip.org added the comment: Ok. Closing as wontfix then. -- resolution: - wont fix stage: - committed/rejected status: open - closed ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue13445 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue14884] Windows Build instruction typo
Roundup Robot devn...@psf.upfronthosting.co.za added the comment: New changeset e55c65fc3cb4 by Eli Bendersky in branch 'default': Issue #14884: fixed a couple of typos in the Windows build instructions. Patch by Michael Driscoll http://hg.python.org/devguide/rev/e55c65fc3cb4 -- nosy: +python-dev ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue14884 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue13934] sqlite3 test typo
Petri Lehtinen pe...@digip.org added the comment: poq: I see you have submitted a few other patches to the tracker, too. For us to be able to use your patches, you should sign the PSF Contributor Agreement as described here: http://www.python.org/psf/contrib/. -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue13934 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue14884] Windows Build instruction typo
Eli Bendersky eli...@gmail.com added the comment: Done (with a tiny fix inserting parens to avoid ambiguity in a sentence). Thanks for the contribution! -- resolution: - fixed stage: patch review - committed/rejected status: open - closed ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue14884 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue14862] os.__all__ is missing some names
Changes by Petri Lehtinen pe...@digip.org: -- title: fdopen not listed in __all__ of os.py - os.__all__ is missing some names ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue14862 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue14862] os.__all__ is missing some names
Roundup Robot devn...@psf.upfronthosting.co.za added the comment: New changeset 352147bbefdb by Petri Lehtinen in branch 'default': #14862: Add missing names to os.__all__ http://hg.python.org/cpython/rev/352147bbefdb -- nosy: +python-dev ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue14862 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue14862] os.__all__ is missing some names
Changes by Petri Lehtinen pe...@digip.org: -- resolution: - fixed stage: needs patch - committed/rejected status: open - closed ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue14862 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue14891] An error in bindings of closures
Amaury Forgeot d'Arc amaur...@gmail.com added the comment: What fails here is the evaluation of x, not the assignment! You are right concerning the assignment, the outer definition has no effect at all. The very presence of x = in the function code turns x into a local variable for the whole function; so 'x + a' fails because the local variable has not value yet. Python, unlike Lisp, defines scopes lexically, not dynamically. There is no previous binding, but local or outer scopes. -- resolution: - invalid status: open - closed ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue14891 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue14892] 'import readline' fails when launching with ''
New submission from olivier-mattelaer olivier.mattel...@uclouvain.be: Hi Everyone, I have found a strange behavior of the import command for the routine readline: The commands (put in the file test.py) is simply: import readline print readline.__doc__ If I run this programs normally (i.e. python2.x test.py) everything runs normally: [tmp]$ python2.7 tmp.py Importing this module enables command line editing using GNU readline. But if I launched it in the following way: python2.X test.py It's stops before finishing the import command (so no output even if I print the output into a file). This doesn't raise any error just stop the program. I tried to add a try...except...finally... but even the finally statement is not executed. Of course, I realize that readline is not that interesting to load with that options. So I would be more than happy if you could indicate me a way to either detect that the user launch the program with '' or a way to avoid readline to stop the program in this situations. Thanks a lot, Olivier -- assignee: ronaldoussoren components: Macintosh messages: 161450 nosy: olivier-mattelaer, ronaldoussoren priority: normal severity: normal status: open title: 'import readline' fails when launching with '' type: crash versions: Python 2.6, Python 2.7 ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue14892 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue14893] Tutorial: Add function annotation example to function tutorial
New submission from Zachary Ware zachary.w...@gmail.com: A couple months ago, I had never before heard of function annotations and came across a function that had them (I don't remember where or what it was). I spent a fair bit of time searching fruitlessly to figure out what the heck that - in the function definition meant. Then finally, a week or two ago, I came across a mention of pep 3107 and function annotations, and figured out what it was that confused me so thoroughly. In an effort to save others from the same confusion, I've put together a small subsection to add to the tutorial about function definition. The text I'm proposing to add is as follows: :ref:`Function annotations function` are completely optional, arbitrary metadata information about user-defined functions. Python itself currently does not use annotations for anything, so this section is just for familiarity with the syntax. Annotations are stored in the :attr:`__annotations__` attribute of the function as a dictionary and have no effect on any other part of the function. Parameter annotations are defined by a colon after the parameter name, followed by an expression evaluating to the value of the annotation. Return annotations are defined by a literal ``-``, followed by an expression, between the parameter list and the colon denoting the end of the :keyword:`def` statement. The following example has a positional argument, a keyword argument, and the return value annotated with nonsense:: def f(ham: 42, eggs: int = 'spam') - Nothing to see here: ... print(Annotations:, f.__annotations__) # print the function's own annotations ... print(Arguments:, ham, eggs) ... f('wonderful') Annotations: {'eggs': class 'int', 'return': 'Nothing to see here', 'ham': 42} Arguments: wonderful spam I'd also like to see a link for - in the index, either to this note or to the relevant paragraph of compound_stmts.rst or both. The attached patch attempts to add such a link to this section, but I'm not certain that it's done properly. Thanks :) -- assignee: docs@python components: Documentation files: annotations_tutorial.patch keywords: patch messages: 161451 nosy: docs@python, zach.ware priority: normal severity: normal status: open title: Tutorial: Add function annotation example to function tutorial type: enhancement versions: Python 3.2, Python 3.3 Added file: http://bugs.python.org/file25684/annotations_tutorial.patch ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue14893 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue14814] Implement PEP 3144 (the ipaddress module)
Roundup Robot devn...@psf.upfronthosting.co.za added the comment: New changeset 0be296605165 by Sandro Tosi in branch 'default': Issue #14814: improve docstrings and arguments value handling, as per Terry J. Reedy's comments http://hg.python.org/cpython/rev/0be296605165 -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue14814 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue14894] distutils.LooseVersion fails to compare number and a word
New submission from Natalia natalia.frydr...@gmail.com: $ python2.7 -c 'from distutils.version import LooseVersion as V; print V(a) V(1)' True $ python3.2 -c 'from distutils.version import LooseVersion as V; print(V(a) V(b))' False $ python3.2 -c 'from distutils.version import LooseVersion as V; print(V(a) V(1))' Traceback (most recent call last): File string, line 1, in module File /usr/lib/python3.2/distutils/version.py, line 70, in __gt__ c = self._cmp(other) File /usr/lib/python3.2/distutils/version.py, line 343, in _cmp if self.version other.version: TypeError: unorderable types: str() int() -- assignee: eric.araujo components: Distutils messages: 161453 nosy: Natalia, eric.araujo, tarek priority: normal severity: normal status: open title: distutils.LooseVersion fails to compare number and a word type: behavior versions: Python 3.1, Python 3.2 ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue14894 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue14814] Implement PEP 3144 (the ipaddress module)
Hynek Schlawack h...@ox.cx added the comment: A small bikeshed as it’s a new module: - there’s only one free line before _collapse_addresses_recursive, _get_prefix_length and _count_righthand_zero_bits. - class IPv6Address docstring has a \n too much - ip_interface, v4_int_to_packed, v6_int_to_packed are missing an empty line at the end of the docstring - the doctstring of _BaseNetwork.hosts is indented - does it make sense to have a shebang in a library? Just wanted to make it even more shiny. :) -- nosy: +hynek ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue14814 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue14894] distutils.LooseVersion fails to compare number and a word
Changes by Piotr Ożarowski pi...@debian.org: -- nosy: +piotr ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue14894 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue14894] distutils.LooseVersion fails to compare number and a word
Changes by Antoine Pitrou pit...@free.fr: -- stage: - needs patch versions: +Python 3.3 -Python 3.1 ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue14894 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue14894] distutils.LooseVersion fails to compare number and a word
Changes by Barry A. Warsaw ba...@python.org: -- nosy: +barry ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue14894 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue14744] Use _PyUnicodeWriter API in str.format() internals
Changes by STINNER Victor victor.stin...@gmail.com: Added file: http://bugs.python.org/file25685/REPORT_32BIT_2.7_3.2_writer ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue14744 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue14744] Use _PyUnicodeWriter API in str.format() internals
Changes by STINNER Victor victor.stin...@gmail.com: Added file: http://bugs.python.org/file25686/REPORT_32BIT_3.3 ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue14744 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue14744] Use _PyUnicodeWriter API in str.format() internals
Changes by STINNER Victor victor.stin...@gmail.com: Added file: http://bugs.python.org/file25687/REPORT_64BIT_2.7_3.2_writer ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue14744 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue14744] Use _PyUnicodeWriter API in str.format() internals
Changes by STINNER Victor victor.stin...@gmail.com: Added file: http://bugs.python.org/file25688/REPORT_64BIT_3.3 ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue14744 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue14744] Use _PyUnicodeWriter API in str.format() internals
Changes by STINNER Victor victor.stin...@gmail.com: Added file: http://bugs.python.org/file25689/faa88c50a3d2.diff ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue14744 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue14814] Implement PEP 3144 (the ipaddress module)
Roundup Robot devn...@psf.upfronthosting.co.za added the comment: New changeset f4f2139202c5 by Sandro Tosi in branch 'default': Issue #14814: minor improvements as suggested by Hynek Schlawack http://hg.python.org/cpython/rev/f4f2139202c5 -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue14814 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue14888] _md5 module crashes on large data
Roundup Robot devn...@psf.upfronthosting.co.za added the comment: New changeset 290d970c011d by Antoine Pitrou in branch '2.7': Issue #14888: Fix misbehaviour of the _md5 module when called on data larger than 2**32 bytes. http://hg.python.org/cpython/rev/290d970c011d -- nosy: +python-dev ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue14888 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue14888] _md5 module crashes on large data
Antoine Pitrou pit...@free.fr added the comment: I've now pushed the fix. Jesus, if you want to propose a test and patch for the _sha1 issue, please open a separate issue. Thanks! -- resolution: - fixed stage: patch review - committed/rejected status: open - closed ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue14888 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue14814] Implement PEP 3144 (the ipaddress module)
Sandro Tosi sandro.t...@gmail.com added the comment: Thanks Hynek: comments committed -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue14814 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue14744] Use _PyUnicodeWriter API in str.format() internals
STINNER Victor victor.stin...@gmail.com added the comment: Because I don't know what should be tested, I wrote a lot a tests in the bench_str.py script. To run the benchmark, use: ./python benchmark.py --file=FILE script bench_str.py Then to compare results: ./python benchmark.py compare_to FILE1 FILE2 FILE3 ... Download scripts from: https://bitbucket.org/haypo/misc/src/tip/python/benchmark.py https://bitbucket.org/haypo/misc/src/tip/python/bench_str.py (I wrote the benchmark.py tool for this issue, it's a a generic tool to create and compare benchmarks.) I attached results on 32 and 64 bits. * Python 2.7 vs 3.2 vs 3.3 (faster-format branch): REPORT_32BIT_2.7_3.2_writer and REPORT_64BIT_2.7_3.2_writer * Python 3.3, UCS4 buffer vs PyAccu vs _PyUnicodeWriter: REPORT_32BIT_3.3 and REPORT_64BIT_3.3 -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue14744 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue14744] Use _PyUnicodeWriter API in str.format() internals
Antoine Pitrou pit...@free.fr added the comment: When posting benchmark numbers, can you please only compared patched against unpatched? I don't think we care about performance compared to 3.2 or 2.7 here, and it would make things more readable. -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue14744 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue14744] Use _PyUnicodeWriter API in str.format() internals
STINNER Victor victor.stin...@gmail.com added the comment: For Python 3.3, _PyUnicodeWriter API is faster than the Py_UCS4 buffer API and PyAccu API in quite all cases, with a speedup between 30% and 100%. But there are some cases where the _PyUnicodeWriter API is slower: fmt=x={}; arg=12.345; fmt.format(arg) fmt={}:; arg=12.345; fmt.format(arg) fmt=x=%s; arg=\u20ac * 3; fmt % arg fmt=%s:; arg=abc; fmt % arg fmt=%s:; arg=\u20ac * 3; fmt % arg fmt=\u20ac[%s]; arg=abc; fmt % arg fmt=\u20ac[%s]; arg=\u20ac * 3; fmt % arg fmt=\u20ac[%s]; arg=12.345; fmt % arg fmt=\u20ac[%s]; arg=2j; fmt % arg -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue14744 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue14744] Use _PyUnicodeWriter API in str.format() internals
STINNER Victor victor.stin...@gmail.com added the comment: When posting benchmark numbers, can you please only compared patched against unpatched? Here you have: REPORT_64BIT_PATCH. -- Added file: http://bugs.python.org/file25690/REPORT_64BIT_PATCH ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue14744 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue14744] Use _PyUnicodeWriter API in str.format() internals
Changes by STINNER Victor victor.stin...@gmail.com: Removed file: http://bugs.python.org/file25689/faa88c50a3d2.diff ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue14744 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue14744] Use _PyUnicodeWriter API in str.format() internals
STINNER Victor victor.stin...@gmail.com added the comment: faster-format.patch: Patch for Python 3.3 optimizing str%args and str.format(args), use _PyUnicodeWriter deeper in formatting. The patch uses different optimizations: * if the result is just a string, copy the string by reference, don't copy it by value. It's not something new, this optimization was already used by the PyAccu API. Examples: - {}.format(str) - %s.format(str) * avoid a temporary buffer to format integers (base 2, 8, 10, 16). Examples: - decimal=%s.format(int) - hex=%x.format(int) - %o.format(int) - {}.format(int) - {:x}.format(int) * don't overallocate the last argument of a format string. Example: - x=%s.format(A * 4096) -- Added file: http://bugs.python.org/file25691/faster-format.patch ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue14744 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue14895] test_warnings.py EnvironmentVariableTests is a bad test
New submission from Miki Tebeka miki.teb...@gmail.com: EnvironmentVariableTests depends on format of string representation of objects. While working on Jython 2.7 the test failed due to: AssertionError: [u'ignore::DeprecationWarning'] != ['ignore::DeprecationWarning'] Attached is a patch to get the output of child process via marshal and also use set so order is not important. -- components: Tests files: tw.diff keywords: patch messages: 161463 nosy: tebeka priority: normal severity: normal status: open title: test_warnings.py EnvironmentVariableTests is a bad test type: enhancement versions: Python 2.7 Added file: http://bugs.python.org/file25692/tw.diff ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue14895 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue14892] 'import readline' hangs when launching with '' on BSD and OS X
Ned Deily n...@acm.org added the comment: I took a quick look at this. It's not just OS X, the following also fails on FreeBSD 8.2: $ python2.7 -c 'import readline' $ $ python2.7 -c 'import readline' $ [1] + Stopped (tty output)python2.7 -c ?import readline It seems to be hanging on a read from stdin, as adding a redirect of stdin to /dev/null prevents the hang: $ python2.7 -c 'import readline' /dev/null [1] 36178 $ [1]+ Donepython2.7 -c 'import readline' /dev/null But, on Debian and Ubuntu, neither case hangs. Also, on OS X, the same hang behavior is observed when linked with either GNU readline or BSD libedit. I'm not sure what the significant difference here is: possibly a BSDism vs Linuxism? -- components: -Macintosh nosy: +ned.deily title: 'import readline' fails when launching with '' - 'import readline' hangs when launching with '' on BSD and OS X type: crash - behavior versions: +Python 3.2, Python 3.3 -Python 2.6 ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue14892 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue14895] test_warnings.py EnvironmentVariableTests is a bad test
Changes by Antoine Pitrou pit...@free.fr: -- nosy: +brett.cannon versions: +Python 3.2, Python 3.3 ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue14895 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue14894] distutils.LooseVersion fails to compare number and a word
Éric Araujo mer...@netwok.org added the comment: Thanks for the report. How did you find this? According to the doc of LooseVersion, 'a' is not valid, so I would like a real example to accept this as a bug. -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue14894 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue14894] distutils.LooseVersion fails to compare number and a word
Barry A. Warsaw ba...@python.org added the comment: On May 23, 2012, at 10:13 PM, Éric Araujo wrote: Thanks for the report. How did you find this? According to the doc of LooseVersion, 'a' is not valid, so I would like a real example to accept this as a bug. It works in Python 2.7 so I think it was viewed as a regression. Python 2.7.3 (default, Apr 20 2012, 22:39:59) [GCC 4.6.3] on linux2 Type help, copyright, credits or license for more information. from distutils.version import LooseVersion as v v('a') v('0') False But if 'a' is invalid, then LooseVersion should refuse to accept it in its constructor, right? -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue14894 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue14895] test_warnings.py EnvironmentVariableTests is a bad test
Philip Jenvey pjen...@underboss.org added the comment: Jython's sys.warnoptions should probably just contain strs instead of unicode. Otherwise I suspect unicode values could break the warnings module's usage of it -- nosy: +pjenvey ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue14895 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue14469] Python 3 documentation links
Changes by Ezio Melotti ezio.melo...@gmail.com: -- nosy: +ezio.melotti ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue14469 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue14893] Tutorial: Add function annotation example to function tutorial
Raymond Hettinger raymond.hettin...@gmail.com added the comment: This looks like a reasonable addition to the tutorial :-) -- nosy: +rhettinger ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue14893 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue14893] Tutorial: Add function annotation example to function tutorial
Changes by Ezio Melotti ezio.melo...@gmail.com: -- nosy: +eric.araujo, ezio.melotti stage: - patch review ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue14893 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue6721] Locks in python standard library should be sanitized on fork
lesha pybug.20.le...@xoxy.net added the comment: So what are you suggesting? That a lock of the default type should raise an error if you try to acquire it when it has been acquired in a previous process? I was suggesting a way to make 'logging' fork-safe. No more, no less. Does what my previous comment make sense in light of this? Using a generation count Sure, that's a good idea. -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue6721 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com