[issue15890] lib2to3 pickles created with wrong permissions
Tomi Pieviläinen added the comment: Tomi, do you find a different behavior in 3.2? No, the behaviour is the same in 2.6-3.2: no compiled files have permissions for other than root, and all non-compiled files do (because install is run with -m 644). What made me report this bug was that 3.3rc1 does not have this behaviour: while the pickles had a bad timestamp, the permissions were just fine, so I assumed that someone had changed the this intentionally. Also this hasn't been a problem in Python2.x. I can install 2.6.8 and 2.7.3 from source without fixing any permissions, and still have a working Python installation. 3.2.3 requires chmoding the lib2to3 pickles, but no other compiled files need to be touched (it seems that they aren't really needed). -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue15890 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue12947] doctest directive examples in library/doctest.html lack the flags
Chris Jerdonek added the comment: I discovered this today as well while reading the doctest documentation. One thing that I never noticed before (and that doesn't seem to be reflected in the comments above) is that many of the code snippet rectangles in the doctest documentation have a small rectangle in the upper-right corner with the text . If you click on one of these small rectangles, most of the text inside the code snippet rectangle disappears. I haven't confirmed this, but I suspect that it is the code snippets with a doctest directive that have this clickable corner. Is this a feature? What is it for? :) -- nosy: +cjerdonek ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue12947 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue15898] OSX TTY bug
Ned Deily added the comment: Sorry, all I can tell you is that, for me, your test produces an empty string as output with either Python 2.7 or 3.3 and, if I remove the time.sleep() call or remove the os.close(slave), testing or btesting is output. I'm not sure what you believe the problem to be or what behavior you expect; you're covering a lot of ground here and much of it is very close to the OS. You are going to need to be a lot more specific than OSX TTY bug. You should describe exactly what failing behavior you observe with what component of Python, 2. how to reproduce it, and 3. exactly what behavior you expect of that component, and 4. if possible, the results of testing on another supported platform. Otherwise, it will be very difficult to help. -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue15898 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue15676] mmap: add empty file check prior to offset check
Charles-François Natali added the comment: You forgot to add an entry in Misc/ACKS. -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue15676 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue15888] ipaddress doctest examples have some errors
Chris Jerdonek added the comment: Attaching patch. The doctests for these three files now all pass (using a newer version of the patch I uploaded to issue 15629). -- keywords: +patch Added file: http://bugs.python.org/file27161/issue-15888-1.patch ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue15888 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue15898] OSX TTY bug
Martin v. Löwis added the comment: If you want to analyse this further, please provide dtruss -f output of the script. Most likely, this is a glitch in the operating system, but not a bug in Python. Unless you can provide more details, or a patch, we are likely to close this issue as works for me. -- nosy: +loewis ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue15898 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue15629] Add to regrtest the ability to run Lib and Doc doctests
Chris Jerdonek added the comment: I am attaching an updated version of the patch for feedback. The latest version of the patch I developed and used in the real-world example of fixing both the module and documentation file doctests for the ipaddress module (and its HOWTO) in issue 15888. The patch includes the following additional features: (1) the user is warned if a user-selected test file contains no tests (2) tests to run can be specified using one or more globs (e.g. fdoc:howto*) (3) the doc directory can be specified relatively (e.g. --docdir Doc) (4) passing --docall adds all doctests to the test run selection (5) passing --docunsafe runs doctests for all selected tests, whether or not the test files are marked doctest safe The patch also includes usage documentation towards the beginning. -- Added file: http://bugs.python.org/file27162/issue-15629-2.patch ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue15629 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue15726] PyState_FindModule false length-comparison fix
Antoine Pitrou added the comment: Oops, sorry, that was a mistake. -- resolution: invalid - fixed ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue15726 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue15899] howto/unicode.rst doctest corrections
New submission from Chris Jerdonek: This issue is to fix Doc/howto/unicode.rst so that its doctests pass when using the doctest module. Patch forthcoming. -- assignee: docs@python components: Documentation keywords: easy messages: 170167 nosy: cjerdonek, docs@python priority: normal severity: normal status: open title: howto/unicode.rst doctest corrections versions: Python 3.3 ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue15899 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue15899] howto/unicode.rst doctest corrections
Chris Jerdonek added the comment: Attaching patch for the default branch. -- keywords: +patch stage: - patch review Added file: http://bugs.python.org/file27163/issue-15899-1.patch ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue15899 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue15896] Sporadic EINVAL in nonblocking pipe os.read when forked child fails on Mac OS
Changes by Denis Bilenko denis.bile...@gmail.com: -- nosy: +Denis.Bilenko ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue15896 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue15895] PyRun_SimpleFileExFlags() can leak a FILE pointer
Christian Heimes added the comment: No, that's not possible. 'fp' is part of the argument to PyRun_SimpleFileExFlags() and never NULL. We need some way to distinguish a externally provided fp from a self-opened fp and fclose(fp) in the latter case. -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue15895 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue15873] datetime cannot parse ISO 8601 dates and times
Changes by Matej Cepl mc...@redhat.com: -- nosy: +mcepl ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue15873 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue15900] Memory leak in PyUnicode_TranslateCharmap()
New submission from Christian Heimes: Objects/unicodeobject.c:PyUnicode_TranslateCharmap() leaks a reference to the variable unicode. PyUnicode_Translate() is also implemented around the helper function _PyUnicode_TranslateCharmap() but it properly decrefs the reference to the first argument. PyUnicode_Translate() also has an obsolete onError goto label. The patch fixes the leak and simplifies PyUnicode_Translate(). CID 719686 -- components: Interpreter Core files: translate_leak.patch keywords: 3.3regression, patch messages: 170170 nosy: christian.heimes priority: normal severity: normal status: open title: Memory leak in PyUnicode_TranslateCharmap() type: resource usage versions: Python 3.3, Python 3.4 Added file: http://bugs.python.org/file27164/translate_leak.patch ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue15900 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue15901] multiprocessing sharedctypes Array don't accept strings
New submission from Simon R: I've simply tested the example reported in the py3k documentation, and it don't works. See the site: http://docs.python.org/py3k/library/multiprocessing.html?highlight=multiprocessing#module-multiprocessing.sharedctypes The program exit with this error: python sha.py Traceback (most recent call last): File sha.py, line 21, in module s = Array('c', 'hello world', lock=lock) File /usr/lib/python3.2/multiprocessing/sharedctypes.py, line 112, in Array obj = RawArray(typecode_or_type, size_or_initializer) File /usr/lib/python3.2/multiprocessing/sharedctypes.py, line 89, in RawArray result.__init__(*size_or_initializer) TypeError: one character string expected Observe that the following code works correctly with python2! I'm using python 3.2.3 and gcc 4.7.1 under ArchLinx Te code is: http://docs.python.org/py3k/library/multiprocessing.html?highlight=multiprocessing#module-multiprocessing.sharedctypes from multiprocessing import Process, Lock from multiprocessing.sharedctypes import Value, Array from ctypes import Structure, c_double class Point(Structure): _fields_ = [('x', c_double), ('y', c_double)] def modify(n, x, s, A): n.value **= 2 x.value **= 2 s.value = s.value.upper() for a in A: a.x **= 2 a.y **= 2 if __name__ == '__main__': lock = Lock() n = Value('i', 7) x = Value(c_double, 1.0/3.0, lock=False) s = Array('c', 'hello world', lock=lock) A = Array(Point, [(1.875,-6.25), (-5.75,2.0), (2.375,9.5)], lock=lock) p = Process(target=modify, args=(n, x, s, A)) p.start() p.join() print((n.value)) print((x.value)) print((s.value)) print([(a.x, a.y) for a in A]) -- components: ctypes messages: 170171 nosy: bred priority: normal severity: normal status: open title: multiprocessing sharedctypes Array don't accept strings type: crash versions: Python 3.2 ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue15901 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue15901] multiprocessing sharedctypes Array don't accept strings
Richard Oudkerk added the comment: The documentation needs updating for Python 3 so that a byte string is used. So the line becomes s = Array('c', b'hello world', lock=lock) -- nosy: +sbt ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue15901 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue15901] multiprocessing sharedctypes Array don't accept strings
Changes by Simon simone.r...@bluewin.ch: -- assignee: - docs@python components: +Documentation -ctypes nosy: +docs@python type: crash - behavior ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue15901 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue15828] imp.load_module doesn't support C_EXTENSION type
Paul Moore added the comment: The applied fix appears to have a regression - the file argument is not allowed to be None. The pywin32 post-install script calls imp.load_module for a C extension with file=None, so presumably this worked in earlier versions. The regression breaks the postinstall script for pywin32, meaning that the start menu shortcuts do not get installed. I do not know if it has any more serious consequences for pywin32. -- nosy: +pmoore ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue15828 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue15828] imp.load_module doesn't support C_EXTENSION type
Tim Golden added the comment: Paul, are you using the hg tip of pywin32? pywin32_postintall.py was patched a couple of months ago to use imp.load_dynamic (essentially to work around this issue). -- nosy: +tim.golden ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue15828 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue15828] imp.load_module doesn't support C_EXTENSION type
Paul Moore added the comment: On 10 September 2012 11:47, Tim Golden rep...@bugs.python.org wrote: Tim Golden added the comment: Paul, are you using the hg tip of pywin32? pywin32_postintall.py was patched a couple of months ago to use imp.load_dynamic (essentially to work around this issue). No, this is the 217 release. Looks like they may need a new release then... Paul -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue15828 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue15828] imp.load_module doesn't support C_EXTENSION type
Nick Coghlan added the comment: Paul, could you please report that issue/question separately? If it's a regression, it's likely in the importlib migration in general and was hidden by this bug rather than being introduced by the fix. -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue15828 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue7358] cStringIO not 64-bit safe
Gilles Louppe added the comment: Hi, Any solution regarding that issue? We are currently encountering the exact same bug when pickling too large objects. Best, Gilles -- nosy: +Gilles.Louppe ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue7358 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue15902] imp.load_module won't accept None for the file argument for a C extension
New submission from Paul Moore: imp.load_module appears to have a regression - the file argument is not allowed to be None when loading a C_EXTENSION. The pywin32 post-install script for version 217 calls imp.load_module for a C extension with file=None, so presumably this worked in earlier versions. Note that apparently pywin32 tip no longer calls load_module in this way, and load_module is marked as deprecated in the documentation, so it is not clear if this issue actually needs fixing. See #15828 for some background. -- components: Library (Lib) keywords: 3.3regression messages: 170178 nosy: brett.cannon, georg.brandl, ncoghlan, pmoore priority: normal severity: normal status: open title: imp.load_module won't accept None for the file argument for a C extension type: behavior versions: Python 3.3 ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue15902 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue15828] imp.load_module doesn't support C_EXTENSION type
Paul Moore added the comment: Logged as #15902. -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue15828 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue15873] datetime cannot parse ISO 8601 dates and times
Roy Smith added the comment: I've started collecting some test cases. I'll keep adding to the collection. I'm going to start trolling ISO 8601:2004(E) for more. Let me know if there are other sources I should be considering. -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue15873 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue15873] datetime cannot parse ISO 8601 dates and times
Roy Smith added the comment: Ooops, clicked the wrong button. -- Added file: http://bugs.python.org/file27165/test-cases.py ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue15873 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue15901] multiprocessing sharedctypes Array don't accept strings
Roundup Robot added the comment: New changeset ddb406904be1 by Richard Oudkerk in branch '3.2': Issue #15901: Change example to use byte string instead of string http://hg.python.org/cpython/rev/ddb406904be1 -- nosy: +python-dev ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue15901 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue15901] multiprocessing sharedctypes Array don't accept strings
Changes by Richard Oudkerk shibt...@gmail.com: -- resolution: - fixed stage: - committed/rejected status: open - closed ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue15901 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue15903] Make rawiobase_read() read directly to bytes object
New submission from Richard Oudkerk: Currently rawiobase_read() reads to a bytearray object and then copies the data to a bytes object. There is a TODO comment saying that the bytes object should be created directly. The attached patch does that. -- files: iobase_read.patch keywords: patch messages: 170183 nosy: sbt priority: normal severity: normal status: open title: Make rawiobase_read() read directly to bytes object Added file: http://bugs.python.org/file27166/iobase_read.patch ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue15903 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue12947] doctest directive examples in library/doctest.html lack the flags
Ezio Melotti added the comment: Is this a feature? What is it for? :) The is added to every example that contains an interactive session to hide the '' and '...' prompts and the output and make the code copy/pastable, and it's not specific to doctests. -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue12947 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue15902] imp.load_module won't accept None for the file argument for a C extension
Brett Cannon added the comment: How can you load a C extension without a file path? Are C extensions being inappropriately flagged as built-in modules on Windows? What does imp.find_module() return for the module being checked? I need more debugging info on what imp.find_module() and imp.load_module() returns in 3.2 and 3.3 before I can make a call on where the actual breakage is. -- status: open - pending ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue15902 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue15902] imp.load_module won't accept None for the file argument for a C extension
Paul Moore added the comment: It's the open file object argument, not the path. I assume that if you supplied None, the code opened the file for you. -- status: pending - open ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue15902 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue15881] multiprocessing 'NoneType' object is not callable
Richard Oudkerk added the comment: I see the same error on Windows (when pressing ^C), but on Linux I get Error in sys.exitfunc: Traceback (most recent call last): File /usr/lib/python2.7/atexit.py, line 28, in _run_exitfuncs import traceback File /usr/lib/python2.7/traceback.py, line 3, in module import linecache File /usr/lib/python2.7/linecache.py, line 9, in module import os File /usr/lib/python2.7/os.py, line 119, in module sys.modules['os.path'] = path AttributeError: 'module' object has no attribute 'modules' This also suggests that module teardown has begun before/while sys.exitfunc is running. -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue15881 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue15904] file,close() can fail assert on Windows in 2.7
New submission from Richard Oudkerk: With Python 2.7 on Windows the following crashes with an assertion: import os [43042 refs] f = open(foobar, wb) [43048 refs] os.close(f.fileno()) [43048 refs] f.close() Failed assertion A box pops up with Program: C:\Repos\cpython-27\PCbuild\python_d.exe File: f:\dd\vctools\crt_bld\self_x86\crt\src\close.c Line: 48 Expression: (_osfile(fh) FOPEN) Python 3.2 and 3.3 give IOError(EBADF, ...) as expected. Compare #15261 and #15263. -- messages: 170188 nosy: sbt priority: normal severity: normal stage: needs patch status: open title: file,close() can fail assert on Windows in 2.7 type: crash versions: Python 2.7 ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue15904 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue14649] doctest.DocTestSuite error misleading when module has no docstrings
Roundup Robot added the comment: New changeset d012f645b8b2 by R David Murray in branch '3.2': #14649: clarify DocTestSuite error when there are no docstrings. http://hg.python.org/cpython/rev/d012f645b8b2 New changeset 6544fc92b528 by R David Murray in branch 'default': Merge #14649: clarify DocTestSuite error when there are no docstrings. http://hg.python.org/cpython/rev/6544fc92b528 New changeset b48ef168d8c5 by R David Murray in branch '2.7': #14649: clarify DocTestSuite error when there are no docstrings. http://hg.python.org/cpython/rev/b48ef168d8c5 -- nosy: +python-dev ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue14649 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue14649] doctest.DocTestSuite error misleading when module has no docstrings
R. David Murray added the comment: Thanks, Chris. -- resolution: - fixed stage: patch review - committed/rejected status: open - closed ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue14649 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue15891] A public facing API for __unittest = True
Eric Snow added the comment: yeah, I keep thinking we need a better API for managing tracebacks. One of these days... -- nosy: +eric.snow ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue15891 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue15904] file,close() can fail assert on Windows in 2.7
Amaury Forgeot d'Arc added the comment: Is it also the case for other file operations? Here is a list that may use a closed FILE object: f.write('something') f.read(1) print f, 'something' f.seek(0) f.tell() f.truncate(0) f.flush() f.isatty() f.readlines() f.writelines(['x']) list(f) -- nosy: +amaury.forgeotdarc ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue15904 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue15896] Sporadic EINVAL in nonblocking pipe os.read when forked child fails on Mac OS
Charles-François Natali added the comment: Looks like - another - OS-X bug. What happens if you reduce the size argument when reading from the error pipe? Try setting it to a value like 512 (minimum guaranteed PIPE_BUF): newData = os.read(errpipe_read, min(512, rSize)) You could also try to put a short sleep before exiting the child process (after pickling the exception) to see what happens if the reader reads before the pipe is closed by the other end (that would be a huge bug, but hey, who knows...). -- nosy: +neologix ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue15896 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue13212] json library is decoding/encoding when it should not
Éric Araujo added the comment: I don't think it should be called strict though, as that would imply that we comply with RFC 4627 strictly (which is not true without passing allow_nan=False for dump() or passing a parse_constant function for load()) What if the strict mode implied both of these things? FWIW, I’m +1 for a doc section about how to achieve strict mode with special arguments and callbacks (if the recent doc patch does not already have that), and +0 on adding it to the code itself. -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue13212 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue15904] file,close() can fail assert on Windows in 2.7
Richard Oudkerk added the comment: If buffering is off then they all fail the assertion except isatty(). -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue15904 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue15419] distutils: build should use a version-specific build directory
Éric Araujo added the comment: It seems to me this is just a special case of the more general issue of building multiple versions of the same distribution, say with multiple versions of Python 2. In general, anytime you change your build environment, you should start with no existing build directory. Maybe Distutils could do that for you. Distutils doesn't keep track of every change you might make in a build environment between invocations of setup.py. Could you detail what you mean with “change in a build environment”? Timestamps are tracked, C headers dependencies too, changes to setup.py (and maybe setup.cfg too), so I think it wouldn’t be a stretch to also track the Python version used to run setup.py. On the other hand, even with the same version there can be differences in the command-line options, the available modules (using Pythons with the same version from different virtual environments), etc. Anyway, using one build directory per version (X.Y.Z) could easily solve a part of these issues. What do people think? -- title: distutils: build_py_2to3 should use a separate build directory - distutils: build should use a version-specific build directory versions: +Python 2.7 ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue15419 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue14649] doctest.DocTestSuite error misleading when module has no docstrings
Roundup Robot added the comment: New changeset c5fc49bc7a5f by R David Murray in branch '2.7': #14649: add sample files omitted from previous checkin. http://hg.python.org/cpython/rev/c5fc49bc7a5f -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue14649 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue15902] imp.load_module won't accept None for the file argument for a C extension
Brett Cannon added the comment: Well, that's extremely annoying as that doesn't work for .py or .pyc files:: import imp stuff = imp.find_module('blah') stuff (_io.TextIOWrapper name=4 mode='U' encoding='utf-8', 'blah.py', ('.py', 'U', 1)) stuff[0].close() imp.load_module('blah', None, 'blah.py', stuff[2]) Traceback (most recent call last): File stdin, line 1, in module ValueError: file object required for import (type code 1) I really hate these functions. -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue15902 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue15902] imp.load_module won't accept None for the file argument for a C extension
Changes by Brett Cannon br...@python.org: -- nosy: +eric.snow ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue15902 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue14649] doctest.DocTestSuite error misleading when module has no docstrings
Chris Jerdonek added the comment: Thanks a lot, David. -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue14649 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue15905] Copy to fixed size buffer w/o check in sys_update_path
New submission from Christian Heimes: In Python/sysmodule.c the function sys_update_path() uses wcscpy to copy data to a fixed size buffer. The input comes from an external source (argv[0]) and could theoretically be larger than the buffer. Suggested solution: Increase the buffer a bit: wchar_t argv0copy[sizeof(wchar_t)* (MAXPATHLEN+1)]; and use wcsncpy: wcsncpy(argv0copy, argv0, MAXPATHLEN); argv0copy[MAXPATHLEN] = L'\0'; CID 486850 -- components: Interpreter Core messages: 170200 nosy: christian.heimes priority: normal severity: normal stage: needs patch status: open title: Copy to fixed size buffer w/o check in sys_update_path type: behavior versions: Python 3.2, Python 3.3, Python 3.4 ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue15905 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue15905] Copy to fixed size buffer w/o check in sys_update_path
Christian Heimes added the comment: search_for_prefix() and search_for_exec_prefix() contain similar code. CID 486612 CID 486611 -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue15905 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue15906] argparse add_argument() confusing behavior when type=str, default=[], action='append'
New submission from Barry A. Warsaw: Run the following code snippet: -snip snip- import argparse parser = argparse.ArgumentParser() parser.add_argument(--test, dest=test, type=str, default=[], action='append') args = parser.parse_args() print args.test, repr(args.test) -snip snip- In Python 3.3 (with the appropriate syntactic changes), args.test is clearly a list. In Python 2.7 and 3.2, args.test is the string []. I can't tell from reading the docs what the expected value should be, but intuitively, the Python 3.3 behavior makes the most sense, i.e. that args.test is a list, not the string representation of a list! Removing type=str from add_argument() fixes the value, but that doesn't seem right because str is the default type so that should have no effect. We discovered this when we tried to do args.test.append('foo') and tracebacked because args.test wasn't a list. Original bug report in Ubuntu: https://launchpad.net/bugs/1048710 but I've tested this with upstream hg head for 2.7, 3.2, and 3.3. It works in Ubuntu's 3.3rc2 but not in upstream head 3.3rc2+, so from reading Misc/NEWS I think the fix for issue #12776 and issue #11839 might be involved. -- messages: 170202 nosy: barry priority: normal severity: normal status: open title: argparse add_argument() confusing behavior when type=str, default=[], action='append' versions: Python 2.7, Python 3.2 ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue15906 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue15906] argparse add_argument() confusing behavior when type=str, default=[], action='append'
Changes by Barry A. Warsaw ba...@python.org: -- nosy: +benjamin.peterson, georg.brandl priority: normal - release blocker ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue15906 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue15906] argparse add_argument() confusing behavior when type=str, default=[], action='append'
Barry A. Warsaw added the comment: Marking it as a release blocker and adding 3.3 since 3.3 hg trunk is affected. -- versions: +Python 3.3 ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue15906 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue15907] move doctest test-data files into a subdirectory of Lib/test
New submission from Chris Jerdonek: doctest currently has 8 data files used for testing that are spread across Lib/test (in addition to the main test files test_doctest.py and test_doctest2.py): doctest_aliases.py sample_doctest.py sample_doctest_no_docstrings.py sample_doctest_no_doctests.py test_doctest.txt test_doctest2.txt test_doctest3.txt test_doctest4.txt This issue is to move these files into a common subdirectory of Lib/test (e.g. Lib/test/doctest). This will simplify the organization of doctest's tests (e.g. by making the supporting files easier to discover) and reduce clutter in the main test directory. Note that test_zipimport_support (and perhaps also test_pyclbr) will also require changes. This issue came out of discussions with R. David Murray in the context of working on issue 14649. -- components: Library (Lib), Tests messages: 170204 nosy: cjerdonek, r.david.murray priority: normal severity: normal status: open title: move doctest test-data files into a subdirectory of Lib/test versions: Python 3.4 ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue15907 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue15906] argparse add_argument() confusing behavior when type=str, default=[], action='append'
Changes by R. David Murray rdmur...@bitdance.com: -- nosy: +bethard ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue15906 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue15899] howto/unicode.rst doctest corrections
Changes by Chris Jerdonek chris.jerdo...@gmail.com: -- versions: +Python 2.7, Python 3.2 ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue15899 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue15906] argparse add_argument() confusing behavior when type=str, default=[], action='append'
Georg Brandl added the comment: I don't see how this affects 3.3: you seem to be saying the behavior is fine there. -- versions: -Python 3.3 ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue15906 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue15906] argparse add_argument() confusing behavior when type=str, default=
Barry A. Warsaw added the comment: On Sep 10, 2012, at 05:21 PM, Georg Brandl wrote: I don't see how this affects 3.3: you seem to be saying the behavior is fine there. No, I thought it was because I tested the Ubuntu rc2 version, but the problem exists in upstream hg 3.3rc2+ head. -- title: argparse add_argument() confusing behavior when type=str, default=[], action='append' - argparse add_argument() confusing behavior when type=str, default= ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue15906 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue15906] argparse add_argument() confusing behavior when type=str, default=
Changes by Barry A. Warsaw ba...@python.org: -- versions: +Python 3.3 ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue15906 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue15882] _decimal.Decimal constructed from tuple
Roundup Robot added the comment: New changeset 97e53273f423 by Stefan Krah in branch 'default': Issue #15882: Change _decimal to accept any coefficient tuple when http://hg.python.org/cpython/rev/97e53273f423 -- nosy: +python-dev ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue15882 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue15895] PyRun_SimpleFileExFlags() can leak a FILE pointer
Jesús Cea Avión added the comment: Look good to me, then. Are you committing the patch yourself?. You can patch 2.7, 3.2 and default, and bug Georg for 3.3.0 inclusion (patches to default will be in 3.3.1), unless Georg is notified and chooses to cherry pick it. -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue15895 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue15906] argparse add_argument() confusing behavior when type=str, default=
Georg Brandl added the comment: But it's not a release blocker for 3.3 then. -- priority: release blocker - high ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue15906 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue15903] Make rawiobase_read() read directly to bytes object
Changes by Jesús Cea Avión j...@jcea.es: -- nosy: +jcea stage: - patch review versions: +Python 3.4 ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue15903 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue15906] argparse add_argument() confusing behavior when type=str, default=
Barry A. Warsaw added the comment: On Sep 10, 2012, at 05:59 PM, Georg Brandl wrote: But it's not a release blocker for 3.3 then. Fair enough! -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue15906 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue15900] Memory leak in PyUnicode_TranslateCharmap()
Jesús Cea Avión added the comment: Looks good to me. Are 2.7/3.2 not affected?. Christian, Please, commit the patch and notify Georg for 3.3.0 inclusion. -- nosy: +jcea ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue15900 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue15676] mmap: add empty file check prior to offset check
Roundup Robot added the comment: New changeset 9ed2e8307e60 by Jesus Cea in branch '2.7': #15676: Proper attribution in Misc/ACKS http://hg.python.org/cpython/rev/9ed2e8307e60 New changeset 4f21f7532038 by Jesus Cea in branch '3.2': #15676: Proper attribution in Misc/ACKS http://hg.python.org/cpython/rev/4f21f7532038 New changeset 4fdc6c501e63 by Jesus Cea in branch 'default': MERGE: #15676: Proper attribution in Misc/ACKS http://hg.python.org/cpython/rev/4fdc6c501e63 -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue15676 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue15874] argparse cannot parse shell variable arguments in file-given arguments
Nat Hillard added the comment: Thank you, everyone. Defining a new type for this is just what I needed. No additional modifications are necessary on top of this new type. -- resolution: - works for me status: open - closed ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue15874 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue15908] SHA1 crashes in 64 bits when the string to hash is
New submission from Jesús Cea Avión: #14888 solves this for MD5, but SHA1 is affected too. -- assignee: jcea messages: 170214 nosy: jcea, pitrou priority: normal severity: normal status: open title: SHA1 crashes in 64 bits when the string to hash is versions: Python 2.7 ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue15908 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue15881] multiprocessing 'NoneType' object is not callable
Richard Oudkerk added the comment: I suspect the problem is caused by nose's isolate plugin. With this enabled, a copy of sys.modules is saved before each test and then restored after the test. This causes garbage collection of newly imported modules. The destructor for the module type causes all globals to be replaced by None. This will break the atexit function registered by multiprocessing since it depends on globals. PS. A simple work-around (which does not require people to upgrade to a bugfixed version of Python) is to put try: import multiprocessing except ImportError: pass near the beginning of setup.py. After this change I don't get the error when running python setup.py test. -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue15881 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue15898] OSX TTY bug
Andrew Moffat added the comment: @Ned, Ok, give me a little time to work up those suggestions. On my machine, the previous script prints testing consistently on 2.7, consistently on 3.2. I guess this is the behavior that is unexpected...it should print the same thing for both versions. But if you are unable to confirm it, that's no good. Let me work on this a little more before you guys close this. @Martin, Thanks for the tip. -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue15898 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue15909] test_mmap failure on Windows buildbots
New submission from Stefan Krah: All Windows bots have multiple failures in test_mmap: == ERROR: test_entire_file (test.test_mmap.MmapTests) -- Traceback (most recent call last): File E:\Data\buildslave\cpython\3.x.snakebite-win2k3r2sp2-x86\build\lib\test\test_mmap.py, line 19, in setUp os.unlink(TESTFN) PermissionError: [WinError 32] The process cannot access the file because it is being used by another process: '@test_8132_tmp' == ERROR: test_error (test.test_mmap.MmapTests) -- Traceback (most recent call last): File E:\Data\buildslave\cpython\3.x.snakebite-win2k3r2sp2-x86\build\lib\test\test_mmap.py, line 19, in setUp os.unlink(TESTFN) PermissionError: [WinError 32] The process cannot access the file because it is being used by another process: '@test_8132_tmp' [...] -- components: Tests messages: 170217 nosy: skrah priority: normal severity: normal stage: needs patch status: open title: test_mmap failure on Windows buildbots type: behavior versions: Python 3.3 ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue15909 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue15908] SHA1 crashes in 64 bits when the string to hash is bigger than 2**32 bytes
Changes by Jesús Cea Avión j...@jcea.es: -- title: SHA1 crashes in 64 bits when the string to hash is - SHA1 crashes in 64 bits when the string to hash is bigger than 2**32 bytes ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue15908 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue15908] SHA1 crashes in 64 bits when the string to hash is bigger than 2**32 bytes
Roundup Robot added the comment: New changeset a13bfc238f27 by Jesus Cea in branch '2.7': Closes #15908: SHA1 crashes in 64 bits when the string to hash is bigger than 2**32 bytes http://hg.python.org/cpython/rev/a13bfc238f27 -- nosy: +python-dev resolution: - fixed stage: - committed/rejected status: open - closed ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue15908 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue15910] MD5 and SHA1 crash when updated with strings bigger than 2**32 bytes
New submission from Jesús Cea Avión: #14888 and #15908 solve the issue for hash.new(), but hash.update() is failing too. -- assignee: jcea messages: 170219 nosy: jcea, pitrou priority: normal severity: normal status: open title: MD5 and SHA1 crash when updated with strings bigger than 2**32 bytes versions: Python 2.7 ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue15910 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue15902] imp.load_module won't accept None for the file argument for a C extension
Changes by Arfrever Frehtes Taifersar Arahesis arfrever@gmail.com: -- nosy: +Arfrever ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue15902 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue15881] multiprocessing 'NoneType' object is not callable
Richard Oudkerk added the comment: Actually, I am not so sure it is the isolate plugin. But I do think that sys.modules is being manipulated somewhere before shutdown. -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue15881 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue15911] Debugging import problems is hard
New submission from Jean-Paul Calderone: Debugging problems involving the frozen importlib._bootstrap is difficult, because the source for importlib._bootstrap is not available to pdb. The bootstrap code can be stepped through, but with only function names and line numbers available, not source lines. The value of having importlib written in Python would be greatly enhanced if it were more like a regular Python module that, eg, pdb could display source lines from. -- components: Interpreter Core, Library (Lib) messages: 170221 nosy: exarkun priority: normal severity: normal status: open title: Debugging import problems is hard versions: Python 3.3 ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue15911 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue15910] MD5 and SHA1 crash when updated with strings bigger than 2**32 bytes
Roundup Robot added the comment: New changeset 4d36e56b56d9 by Jesus Cea in branch '2.7': Closes #15910: MD5 and SHA1 crash when updated with strings bigger than 2**32 bytes http://hg.python.org/cpython/rev/4d36e56b56d9 -- nosy: +python-dev resolution: - fixed stage: - committed/rejected status: open - closed ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue15910 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue11943] Add TLS-SRP (RFC 5054) support to ssl, _ssl, http, and urllib
Jesús Cea Avión added the comment: Ping!. -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue11943 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue15911] Debugging import problems is hard
Eric Snow added the comment: This comes back to #14657, which addressed the frozen vs. non-frozen copies of importlib. It sounds like one useful solution for your situation would be for _frozen_importlib to be used only long enough for bootstrap purposes. This was discussed in that other issue. -- nosy: +eric.snow ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue15911 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue15912] Intermittent import failure
New submission from Jean-Paul Calderone: The attached unit test fails with an ImportError... sometimes. Here's a little blob of shell that seems to make the failure come up more quickly: while ~/Projects/cpython/3.3/python -m unittest -v test_broken_import; do rm -rf test_broken_import; rm -rf __pycache__/; done An example of the output when I run it: exarkun@top:/tmp$ while ~/Projects/cpython/3.3/python -m unittest -v test_broken_import_minimal; do rm -rf test_broken_import; rm -rf __pycache__/; done test_renamedSource (test_broken_import_minimal.BrokenTests) ... ok -- Ran 1 test in 0.004s OK test_renamedSource (test_broken_import_minimal.BrokenTests) ... ok -- Ran 1 test in 0.005s OK test_renamedSource (test_broken_import_minimal.BrokenTests) ... /tmp/test_broken_import_minimal.py(53)test_renamedSource() - print(e) (Pdb) c No module named 'twisted_renamed_helper' ERROR == ERROR: test_renamedSource (test_broken_import_minimal.BrokenTests) -- Traceback (most recent call last): File ./test_broken_import_minimal.py, line 50, in test_renamedSource from twisted_renamed_helper import module ImportError: No module named 'twisted_renamed_helper' -- Ran 1 test in 0.759s FAILED (errors=1) -- components: Interpreter Core files: test_broken_import_minimal.py messages: 170225 nosy: exarkun priority: normal severity: normal status: open title: Intermittent import failure versions: Python 3.3 Added file: http://bugs.python.org/file27168/test_broken_import_minimal.py ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue15912 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue15903] Make rawiobase_read() read directly to bytes object
Amaury Forgeot d'Arc added the comment: It works as along as the bytes object cannot leak to Python code, (imagine a custom readinto() method which plays with gc.get_referrers, then calls hash(b)...) This is OK with this patch. -- nosy: +amaury.forgeotdarc ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue15903 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue15896] Sporadic EINVAL in nonblocking pipe os.read when forked child fails on Mac OS
Vitaly added the comment: Per Charles-François Natali (neologix), I tried the following: 1. Reduce the initial read size argument (rSize in my code snippet) from 1048576 (1MB, the same amount as used by subprocess.Popen._executeChild) to 100: the problem appears to go away (could be just red herring, though); this actually makes me think that it's a Python implementation problem on MacOS - why should an initial read request with 1048576 read size trigger EINVAL every other time (1,3,5,9, etc.), but using the initial size of 100 doesn't? 2. put a short sleep before exiting the child process (after pickling the exception) to see what happens if the reader reads before the pipe is closed by the other end -- I took that to mean a delay after the os.write(errpipe_write, pickle.dumps(exc_value)) call in my snippet: I tried 1, 2, and 4-second delays (via time.sleep()). One time, I saw the Invalid Argument in only one of the 9 iterations, but in all the other runs Invalid Argument showed up as before on iterations: 1, 3, 5, 7, 9 3. put the delay (tried with 1 and 2 seconds) before os.write(errpipe_write, pickle.dumps(exc_value)): Invalid Argument showed up as before on iterations: 1, 3, 5, 7, 9 -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue15896 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue15909] test_mmap failure on Windows buildbots
Stefan Krah added the comment: Duplicate. -- resolution: - duplicate stage: needs patch - committed/rejected status: open - closed superseder: - mmap: add empty file check prior to offset check ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue15909 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue15676] mmap: add empty file check prior to offset check
Stefan Krah added the comment: For some reason all Windows buildbots are failing since f962ec8e47a1: == ERROR: test_entire_file (test.test_mmap.MmapTests) -- Traceback (most recent call last): File D:\Buildslave\3.x.moore-windows\build\lib\test\test_mmap.py, line 19, in setUp os.unlink(TESTFN) PermissionError: [WinError 32] The process cannot access the file because it is being used by another process: '@test_2636_tmp' == ERROR: test_error (test.test_mmap.MmapTests) -- Traceback (most recent call last): File D:\Buildslave\3.x.moore-windows\build\lib\test\test_mmap.py, line 19, in setUp os.unlink(TESTFN) PermissionError: [WinError 32] The process cannot access the file because it is being used by another process: '@test_2636_tmp' == [...] -- nosy: +skrah resolution: fixed - status: closed - open ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue15676 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue15912] Intermittent import failure
Eric Snow added the comment: The FileFinder class (a path entry finder) uses a cache to efficiently track changes to files. You can manually clear this cache by calling importlib.invalidate_caches(). The Python test suite has several examples of clearing the FileFinder cache in this way. I've verified the failure as described. Using importlib.invalidate_caches() at the spot where the script cleans up sys.modules, the failure goes away. Depending on OS filesystem timestamp resolution, you could see the behavior just as you've described it. Since normally you wouldn't remove and re-add modules like this, it isn't normally an issue. -- nosy: +eric.snow stage: - test needed type: - behavior ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue15912 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue15881] multiprocessing 'NoneType' object is not callable
Richard Oudkerk added the comment: Actually it is test.with_project_on_sys_path() in setuptools/commands/test.py that does the save/restore of sys.modules. See http://www.eby-sarna.com/pipermail/peak/2010-May/003357.html -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue15881 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue15676] mmap: add empty file check prior to offset check
Stefan Krah added the comment: This gets rid of the permission error: diff -r f962ec8e47a1 Lib/test/test_mmap.py --- a/Lib/test/test_mmap.py Mon Sep 10 01:23:05 2012 +0200 +++ b/Lib/test/test_mmap.py Mon Sep 10 22:22:38 2012 +0200 @@ -491,11 +491,11 @@ def test_empty_file (self): f = open (TESTFN, 'w+b') f.close() -f = open(TESTFN, rb) -self.assertRaisesRegex(ValueError, - cannot mmap an empty file, - mmap.mmap, f.fileno(), 0, access=mmap.ACCESS_READ) -f.close() +with open(TESTFN, rb) as f: +self.assertRaisesRegex(ValueError, + cannot mmap an empty file, + mmap.mmap, f.fileno(), 0, + access=mmap.ACCESS_READ) def test_offset (self): f = open (TESTFN, 'w+b') But the test still fails: == CPython 3.3.0rc2+ (default, Sep 10 2012, 22:01:26) [MSC v.1600 64 bit (AMD64)] == Windows-7-6.1.7601-SP1 little-endian == C:\Users\stefan\pydev\cpython\build\test_python_2908 Testing with flags: sys.flags(debug=0, inspect=0, interactive=0, optimize=0, dont_write_bytecode=0, no_use r_site=0, no_site=0, ignore_environment=0, verbose=0, bytes_warning=0, quiet=0, hash_randomization=1) [1/1] test_mmap test_empty_file (test.test_mmap.MmapTests) ... FAIL == FAIL: test_empty_file (test.test_mmap.MmapTests) -- ValueError: mmap offset is greater than file size During handling of the above exception, another exception occurred: Traceback (most recent call last): File C:\Users\stefan\pydev\cpython\lib\test\test_mmap.py, line 498, in test_empty_file access=mmap.ACCESS_READ) AssertionError: cannot mmap an empty file does not match mmap offset is greater than file size -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue15676 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue8109] Server-side support for TLS Server Name Indication extension
Jesús Cea Avión added the comment: Daniel, your patch looks quite interesting. Please, send a contributor agreement to the PSF: http://www.python.org/psf/contrib/contrib-form-python/ . Let me know when you status have changed. Why are you changing Lib/test/keycert2.pem? Please, provide also a documentation patch. This is a feature enhancement. Would be applied to 3.4, it is too late for 3.3 :-(. Too bad! :( -- stage: needs patch - patch review ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue8109 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue8109] Server-side support for TLS Server Name Indication extension
Changes by Jesús Cea Avión j...@jcea.es: -- versions: +Python 3.4 -Python 3.3 ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue8109 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue15676] mmap: add empty file check prior to offset check
Roundup Robot added the comment: New changeset 25d477647a2d by Jesus Cea in branch '2.7': #15676: mmap: add empty file check prior to offset check - Previous patch was incomplete http://hg.python.org/cpython/rev/25d477647a2d -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue15676 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue15676] mmap: add empty file check prior to offset check
Roundup Robot added the comment: New changeset 88a88c32661e by Jesus Cea in branch '3.2': #15676: mmap: add empty file check prior to offset check - Previous patch was incomplete http://hg.python.org/cpython/rev/88a88c32661e New changeset 0ac94ae29abe by Jesus Cea in branch 'default': #15676: mmap: add empty file check prior to offset check - Previous patch was incomplete http://hg.python.org/cpython/rev/0ac94ae29abe -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue15676 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue15676] mmap: add empty file check prior to offset check
Stefan Krah added the comment: I think Py_DECREF(m_obj) is missing (at least in 3.3, I didn't look at the other versions). -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue15676 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue15676] mmap: add empty file check prior to offset check
Roundup Robot added the comment: New changeset 39efccf7a167 by Jesus Cea in branch '2.7': #15676: mmap: add empty file check prior to offset check - Previous patch was incomplete (fix 2) http://hg.python.org/cpython/rev/39efccf7a167 New changeset 56a2e862561c by Jesus Cea in branch '3.2': #15676: mmap: add empty file check prior to offset check - Previous patch was incomplete (fix 2) http://hg.python.org/cpython/rev/56a2e862561c New changeset 306b2ecb1a3e by Jesus Cea in branch 'default': MERGE: #15676: mmap: add empty file check prior to offset check - Previous patch was incomplete (fix 2) http://hg.python.org/cpython/rev/306b2ecb1a3e -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue15676 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue15912] Intermittent import failure
Changes by Eric Snow ericsnowcurren...@gmail.com: -- status: open - pending ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue15912 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue13896] Make shelf instances work with 'with' as context managers
Changes by Berker Peksag berker.pek...@gmail.com: -- versions: +Python 3.4 -Python 3.3 ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue13896 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue15896] Sporadic EINVAL in nonblocking pipe os.read when forked child fails on Mac OS
Charles-François Natali added the comment: 1. Reduce the initial read size argument (rSize in my code snippet) from 1048576 (1MB, the same amount as used by subprocess.Popen._executeChild) to 100: the problem appears to go away (could be just red herring, though); this actually makes me think that it's a Python implementation problem on MacOS - why should an initial read request with 1048576 read size trigger EINVAL every other time (1,3,5,9, etc.), but using the initial size of 100 doesn't? That's not a Python issue. os.read() juste calls the read() syscall, nothing more. Failing with EBADF could maybe have an explanation if we endup up calling read() on a closed FD, but nothing can explain EINVAL. We've had many cases of strange OS-X bugs, like this one (EINVAL too): http://bugs.python.org/issue15594 One last thing I'd like to make sure of, is trying to put a delay before reading the exception from the pipe. There may be cases where read() returns EINVAL instead of EAGAIN when there's no data in the pipe. -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue15896 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue15913] PyBuffer_SizeFromFormat is missing
New submission from Ellery Newcomer: this function is listed in the buffer docs and in abstract.h, but there is no implementation anywhere. -- components: None messages: 170239 nosy: ellery.newcomer priority: normal severity: normal status: open title: PyBuffer_SizeFromFormat is missing versions: Python 2.7, Python 3.1 ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue15913 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue15914] multiprocessing.SyncManager connection hang
New submission from Sean B. Palmer: create.py: import multiprocessing manager = multiprocessing.Manager() namespace = manager.Namespace() print(create.py complete) run.py: import create print(run.py complete) Correct behaviour occurs for create.py: $ python3 create.py create.py complete INCORRECT behaviour occurs for run.py: $ python3 run.py No output, because it hangs. On SIGINT: ^CTraceback (most recent call last): File run.py, line 1, in module import create File [...]/create.py, line 7, in module test() File [...]/create.py, line 5, in test namespace = manager.Namespace() File /Library/Frameworks/Python.framework/Versions/3.2/lib/python3.2/multiprocessing/managers.py, line 670, in temp token, exp = self._create(typeid, *args, **kwds) File /Library/Frameworks/Python.framework/Versions/3.2/lib/python3.2/multiprocessing/managers.py, line 568, in _create conn = self._Client(self._address, authkey=self._authkey) File /Library/Frameworks/Python.framework/Versions/3.2/lib/python3.2/multiprocessing/connection.py, line 175, in Client answer_challenge(c, authkey) File /Library/Frameworks/Python.framework/Versions/3.2/lib/python3.2/multiprocessing/connection.py, line 412, in answer_challenge message = connection.recv_bytes(256) # reject large message KeyboardInterrupt $ python3 Python 3.2.3 (v3.2.3:3d0686d90f55, Apr 10 2012, 11:25:50) [GCC 4.2.1 (Apple Inc. build 5666) (dot 3)] on darwin This appears to be a duplicate of this *closed* bug: http://bugs.python.org/issue7474 This was closed because nobody could reproduce the behaviour on Python 3. I have reproduced it, but I don't know how to reopen that bug, so I'm filing this one. The test case in 7474 also fails for me. -- messages: 170240 nosy: palmer priority: normal severity: normal status: open title: multiprocessing.SyncManager connection hang type: crash versions: Python 3.2 ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue15914 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue15676] mmap: add empty file check prior to offset check
Jesús Cea Avión added the comment: Thanks for the heads-up, Stefan. -- assignee: - jcea resolution: - fixed status: open - closed ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue15676 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue15915] array.array does not support the buffer interface
New submission from Ellery Newcomer: According to http://docs.python.org/library/array.html, array.array supports the buffer interface; however in python 2.7, PyObject_CheckBuffer says this is not the case. all is well in python 3.2, though. -- files: test.c messages: 170242 nosy: ellery.newcomer priority: normal severity: normal status: open title: array.array does not support the buffer interface versions: Python 2.7 Added file: http://bugs.python.org/file27169/test.c ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue15915 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue15915] array.array does not support the buffer interface
Changes by STINNER Victor victor.stin...@gmail.com: -- nosy: +skrah ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue15915 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com