[issue11820] idle3 shell os.system swallows shell command output
Ned Deily n...@acm.org added the comment: I agree that it is kind of odd behavior and, after a quick look back through open issues, I was a bit surprised to not find an open issue about it (although I may have overlooked one). Thus it does not seem to be an os.system issue, but a failure of Idle to capture the sysoutput string as the interpreter does The xterminal example highlights this. The sysoutput is echoed at the xterminal not in idle. The reason this is an issue is because the interpreter does *not* do anything special to capture stdout from subprocesses. If you're running the interpreter in a terminal window both stdout from the interpreter process and, by default, stdout from any child processes, like those created by os.system or subprocess (if you don't override it), inherit the same stdout and so the output from both processes show up in the same place (i.e. terminal session) automatically. When running under IDLE though, IDLE uses its own proxy output object to intercept the output from the interpreter but does not do anything special for stdout from subprocesses so that output ends up in unexpected places: the terminal session from which IDLE was launched or the transient window on Windows or into the system log with the OS X IDLE.app. I think IDLE could do a better job of intercepting stdout for these cases but it might be a bit tricky to make it work across all platforms. -- components: -Interpreter Core nosy: +ned.deily stage: - needs patch ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue11820 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue11854] __or__ et al instantiate subclass of set without calling __init__
Changes by Raymond Hettinger raymond.hettin...@gmail.com: -- assignee: - rhettinger nosy: +rhettinger ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue11854 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue11853] idle3.2 on mac unresponsive on input() called from a source file
Ned Deily n...@acm.org added the comment: Thanks for the report. This is the same problem as reported in Issue11088. A fix will be available in the next releases of Python 3.2 and 2.7. A workaround is to use the 32-bit-only version of Python 3.2 which uses the Tcl/Tk 8.4 or to not try to do input() in an editor window. -- assignee: - ned.deily nosy: +ned.deily resolution: - duplicate stage: - committed/rejected status: open - closed superseder: - IDLE on OS X with Cocoa Tk 8.5 can hang waiting on input / raw_input type: crash - behavior ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue11853 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue11851] Flushing the standard input causes an error
Ned Deily n...@acm.org added the comment: Given that it is undefined, the puzzle is that it exists at all, even to be called. No puzzle at all: in Python 2, stdin is a file object which automatically has a flush method. And the behavior seen here is not limited to OS X; FreeBSD, for one, gives exactly the same error. -- components: -Macintosh nosy: +ned.deily ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue11851 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue10665] Expand unicodedata module documentation
Georg Brandl ge...@python.org added the comment: Can y'all please accept the limitation to latin-1? Like Marc-Andre says, the more exotic the examples, the less likely it is that users reading the HTML can display it anyway. -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue10665 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue11820] idle3 shell os.system swallows shell command output
kent fuzzba...@comcast.net added the comment: I had kind of figured it might be something like this. I ran the following code in the xterm interpreter: x=subprocess.call('ls') bin Documents eclipse local Pictures tmp workspace Desktop Downloads hamlib Music Templates Videos print(x) 0 It does not capture the output. -- components: +Interpreter Core ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue11820 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue11820] idle3 shell os.system swallows shell command output
kent fuzzba...@comcast.net added the comment: The getoutput and getstatusoutput provide the expect output which can be captured x=subprocess.getoutput('ls') print(x) hs_err_pid28274.log LP4E-examples mydir.pth mydir.pth~ PP4E-Examples-1.2 ProgMan Python_dir Would it be a good thing to have the interpreter capture the sysout of all child processes automatically? -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue11820 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue11806] Missing 2 hyphens in the docs
Changes by Boštjan Mejak bostjan.me...@gmail.com: Removed file: http://bugs.python.org/file21638/unnamed ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue11806 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue11806] Missing 2 hyphens in the docs
Changes by Boštjan Mejak bostjan.me...@gmail.com: Removed file: http://bugs.python.org/file21643/unnamed ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue11806 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue11806] Missing 2 hyphens in the docs
Changes by Boštjan Mejak bostjan.me...@gmail.com: Removed file: http://bugs.python.org/file21648/unnamed ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue11806 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue11806] Missing 2 hyphens in the docs
Changes by Boštjan Mejak bostjan.me...@gmail.com: Removed file: http://bugs.python.org/file21654/unnamed ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue11806 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue11806] Missing 2 hyphens in the docs
Changes by Boštjan Mejak bostjan.me...@gmail.com: Removed file: http://bugs.python.org/file21664/unnamed ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue11806 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue11855] urlretrieve -- urlretrieve()
New submission from Boštjan Mejak bostjan.me...@gmail.com: A typo in the docs was found here: http://docs.python.org/library/urllib.html#urllib.urlretrieve Two instances of the word urlretrieve need to be urlretrieve(), as other instances of it are, with that fancy color and a link-like look. You know what I mean. If you care, please fix this. -- assignee: docs@python components: Documentation messages: 133887 nosy: Retro, docs@python priority: normal severity: normal status: open title: urlretrieve -- urlretrieve() 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/issue11855 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue11855] urlretrieve -- urlretrieve()
Eli Bendersky eli...@gmail.com added the comment: Agreed. Will fix -- keywords: +easy nosy: +eli.bendersky priority: normal - low resolution: - accepted versions: -Python 3.4 ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue11855 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue11855] urlretrieve -- urlretrieve()
Roundup Robot devnull@devnull added the comment: New changeset d3e0bc155ca2 by Eli Bendersky in branch '2.7': Issue #11855: Apply missing formatting for urlretrieve http://hg.python.org/cpython/rev/d3e0bc155ca2 -- nosy: +python-dev ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue11855 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue11855] urlretrieve -- urlretrieve()
Roundup Robot devnull@devnull added the comment: New changeset a6d9f9329070 by Eli Bendersky in branch '3.1': Issue #11855: Apply missing formatting for urlretrieve http://hg.python.org/cpython/rev/a6d9f9329070 New changeset 0f1199858714 by Eli Bendersky in branch '3.2': Issue #11855: merge from 3.1 http://hg.python.org/cpython/rev/0f1199858714 New changeset c49c595e4214 by Eli Bendersky in branch 'default': Issue #11855: merge from 3.2 http://hg.python.org/cpython/rev/c49c595e4214 -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue11855 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue11856] Optimize parsing of JSON numbers
New submission from Antoine Pitrou pit...@free.fr: In Python 3.x, parsing JSON numbers involve calling PyLong_FromUnicode or PyFloat_FromString with an unicode object. These functions are quite costly because they call PyUnicode_TransformDecimalToASCII(). But JSON numbers are always pure ASCII. This patch does the ASCII conversion ourselves. Small benchmark with integers: ./python -m timeit -s \ from json import loads, dumps; d=list(i for i in range(1000)); s=dumps(d) \ loads(s) - without patch: 705 usec per loop - with patch: 103 usec per loop -- components: Library (Lib) files: jsonnumbers.patch keywords: patch messages: 133891 nosy: mark.dickinson, pitrou, rhettinger priority: normal severity: normal stage: patch review status: open title: Optimize parsing of JSON numbers type: performance versions: Python 3.3 Added file: http://bugs.python.org/file21681/jsonnumbers.patch ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue11856 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue11855] urlretrieve -- urlretrieve()
Changes by Eli Bendersky eli...@gmail.com: -- resolution: accepted - fixed status: open - pending ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue11855 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue11856] Optimize parsing of JSON numbers
Changes by Ezio Melotti ezio.melo...@gmail.com: -- nosy: +ezio.melotti ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue11856 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue11277] test_zlib.test_big_buffer crashes under BSD (Mac OS X and FreeBSD)
Nadeem Vawda nadeem.va...@gmail.com added the comment: So i finally did some tests using Nadeem's code snippet from msg133677. The largest top(1) i ever got was 30477 python3 2.7 00:09.77 101877912M+ 240K but the system is unusable then. The code I posted was only intended to run on machines with at least 4GB of free memory. The precisionbigmemtest decorator should cause it to be skipped on machines with less RAM. Except for all this i don't understand this thread. Isn't that bot the one for which haypo has noticed those random failures??? The current status of this issue (as I understand it) is: * test_zlib's test_big_buffer() is failing sporadically on the AMD64 Snow Leopard buildbot (http://www.python.org/dev/buildbot/all/builders/AMD64%20Snow%20Leopard%203.x/) * The cause seems to be a bug in OS X's handling of mmap()'d files, not a problem with the Python code. * Antoine has proposed skipping this test on OS X as a workaround, and no-one has objected to this. I don't think it is necessary to further investigate the behaviour of Snow Leopard's mmap() - we know that it's broken, and we have a fix. At the moment, we need someone to actually write and commit the fix. I would do it myself, but I'm hesitant to commit code without testing it, and don't have access to a Mac system. -- stage: committed/rejected - needs patch ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue11277 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue11857] Hyphenate the argparse.rst file, patch added
New submission from Boštjan Mejak bostjan.me...@gmail.com: Please apply this patch. And fix the occurences where you think the word command line acts as a noun. -- assignee: docs@python components: Documentation files: argparse.patch keywords: patch messages: 133893 nosy: Retro, docs@python, georg.brandl priority: normal severity: normal status: open title: Hyphenate the argparse.rst file, patch added versions: Python 3.2, Python 3.3, Python 3.4 Added file: http://bugs.python.org/file21682/argparse.patch ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue11857 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue11277] test_zlib.test_big_buffer crashes under BSD (Mac OS X and FreeBSD)
Steffen Daode Nurpmeso sdao...@googlemail.com added the comment: Yet another bug of Mac OS X: it sometimes creates messed up sparse regions: 14:00 ~/tmp/test $ ~/src/cpython/python.exe test_mmap.py .. 14:01 ~/tmp/test $ zsum32 py-mmap-testfile Adler-32 db8d743c CRC-32 78ebae7a -- py-mmap-testfile 14:03 ~/tmp/test $ ./test_mmap Size 4294971396/0x11004: open. lseek. write. fsync. fstat. mmap. [0]. [s.st_size-4]. munmap. 14:04 ~/tmp/test $ zsum32 c-mmap-testfile Adler-32 14b9018b CRC-32 c6e340bf -- c-mmap-testfile 14:08 ~/tmp/test $ hexdump -C -s 4000 -n 128 c-mmap-testfile 0fa0 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 || * 1020 14:08 ~/tmp/test $ hexdump -C -s 4000 -n 128 py-mmap-testfile 0fa0 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 || * 1000 db db db db db db db db db db db db db db db db || * 1020 Conclusions: 1. It is unwise to create memory regions GT hw.usermem=1651843072 // 2 and extremely unwise to do so for regions GT hw.user_wire_limit=1811939328 // 2 Exceeding this limit and Mac OS X effectively enters an endless loop which may cause so much paging activity that the system is almost locked. (P.S.: if you invoke diff(1) on two extremely large files you may produce an unkillable process which survives SIGKILL and Activity Monitor initiated Force Quits; not to talk about termination of the parent shell.) 2. Mac OS X does not reliably produce sparse files. If the attached files 11277.mmap-2.c and 11277.mmap-2.py are modified not to unlink(2) the produced files (not hard for the Python version), then: cmp --verbose py-mmap-testfile c-mmap-testfile | wc 95832 287496 1820808 3. For at least sparse files the VMS of Mac OS X is unable to create an accessible mmap(2)ing if the size of the mapping is in the inclusive range UINT32_MAX+1 .. UINT32_MAX + PAGESIZE (== 4096) and the file has been written to. Closing the file and reopening it will make the mapping not only succeed but also accessible (talking about Python). 4. If you chose a size which does not fail immediately, then if you don't reopen but only instrument mmapmodule.c then subscript self=0x100771350 CALCULATED SUBSCRIPT 4095 subscript self=0x100771350 CALCULATED SUBSCRIPT 4096 Bus Error Thus, accessing the first byte of the second page causes Python to fail with SIGBUS, *even* if you explicitely fsync() the fd in new_mmap_object(); fstat(2) code runs anyway. The C version does *not* have this problem, here fsync() alone does the magic. 5. Python's C code: mumble mumble mumble. That really needs to be said at least. 6. The error is in mmapmodule.c, function new_mmap_object(). It is the call to mmap(2). Wether i dup(2) or not. Whatever i do. Even if i reduce new_mmap_object() to the running code from 11277.mmap-2.c: if (fd != -1 fstat(fd, st) == 0 S_ISREG(st.st_mode) map_size == 0) map_size = st.st_size; fprintf(stderr,before mmap(2): size=%lu,fd=%d\n,(size_t)map_size, fd); {void *addr = mmap(NULL, (size_t)map_size, PROT_READ, MAP_SHARED, fd, 0); fprintf(stderr, after mmap(2): size=%lu,fd=%d got address=%p\n,(size_t)map_size, fd, addr); {size_t j; for (j = 0; j map_size; ++j) { char x; if (j % 1024 == 0) fprintf(stderr, INDEX %lu\n,j); x = ((volatile char*)addr)[j] } fprintf(stderr, PASSED ALL INDICIES\n); exit(1); } } ... 17:41 ~/tmp/test $ ~/src/cpython/python.exe 11277.mmap-2.py DESCRIPTOR FLAGS WILL BE 0 DESCRIPTOR FLAGS WILL BE 0 Start: time.struct_time(tm_year=2011, tm_mon=4, tm_mday=16, tm_hour=15, tm_min=41, tm_sec=22, tm_wday=5, tm_yday=106, tm_isdst=0) Testing file size 4294971400: DESCRIPTOR FLAGS WILL BE 1538 new_mmap_object _GetMapSize o=0x1001f5d10 before mmap(2): size=4294971396,fd=3 after mmap(2): size=4294971396,fd=3 got address=0x10114 INDEX 0 INDEX 1024 INDEX 2048 INDEX 3072 INDEX 4096 Bus error 7. Note the C version also works if i prepend many malloc(3) calls. 8. I have no idea what Python does here. Maybe it's ld(1) and dynamic module-loading related. Maybe Apples VM gets confused about memory regions if several conditions come together. I have no idea of what Python does along it's way to initialize itself. It's a lot. And i'm someone who did not even look into Doc/c-api/ at all yet except for a grep -Fr tp_as_buf Doc/ today (the first version of the iterate-cpl-buffer used buffer interface). So please explain any comments you might give. Maybe i'll write a patch to add tests to test_mmap.py. Beside that i'm out of this. 9. Maybe it's really better to simply skip this on Mac OS X. Z. ... and maybe someone with a name should ask someone with a name-name-name to ask those californian ocean surfers to fix at least some of the OS bugs? My bug reports are not
[issue11155] multiprocessing.Queue's put() signature differs from docs
Westley Martínez aniko...@gmail.com added the comment: Can this patch be commited? -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue11155 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue11277] test_zlib.test_big_buffer crashes under BSD (Mac OS X and FreeBSD)
Steffen Daode Nurpmeso sdao...@googlemail.com added the comment: On Sat, Apr 16, 2011 at 02:55:29PM +, Nadeem Vawda wrote: I don't think it is necessary to further investigate the behaviour of Snow Leopard's mmap() - we know that it's broken, and we have a fix. At the moment, we need someone to actually write and commit the fix. I would do it myself, but I'm hesitant to commit code without testing it, and don't have access to a Mac system. I see. -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue11277 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue11858] configparser.ExtendedInterpolation and section case
New submission from Pink cias...@gmail.com: configparser.ExtendedInterpolation in Python 3.2 has a bug that it will convert the section name in the interpolation to lowercase, and lead to an exception of NoSectionError if the section name has letters in uppercase. In fact it just cannot pass the test of the second example in the doc (http://docs.python.org/py3k/library/configparser.html#configparser.ExtendedInterpolation). The attached patch should fix it. -- components: Library (Lib) files: configparser.diff keywords: patch messages: 133897 nosy: ciasoms, lukasz.langa priority: normal severity: normal status: open title: configparser.ExtendedInterpolation and section case type: behavior versions: Python 3.2 Added file: http://bugs.python.org/file21685/configparser.diff ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue11858 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue11851] Flushing the standard input causes an error
Roger Binns pyt...@rogerbinns.com added the comment: I'm the APSW author. The reason why this apparent nonsense is done is due to using readline and completion. That requires being able to write to standard input when it is a terminal - something that Windows and Linux are happy to do. In any event I'll put a try/catch around this and ignore. -- nosy: +rogerbinns ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue11851 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue11854] __or__ et al instantiate subclass of set without calling __init__
Changes by Daniel Stutzbach stutzb...@google.com: -- nosy: +stutzbach ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue11854 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue11856] Optimize parsing of JSON numbers
Antoine Pitrou pit...@free.fr added the comment: Cleaned up patch. -- Added file: http://bugs.python.org/file21686/jsonnumbers2.patch ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue11856 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue11005] Assertion error on RLock._acquire_restore
Antoine Pitrou pit...@free.fr added the comment: Here is a patch: Antoine, would you like to review it? -- keywords: +patch nosy: +pitrou Added file: http://bugs.python.org/file21636/rlock_release_save.patch Well, it looks ok to me. Is the assert still needed? -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue11005 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue11790] transient failure in test_multiprocessing.WithProcessesTestCondition
Antoine Pitrou pit...@free.fr added the comment: Indeed, it just seems that the sleep period is sometimes too low. Will commit a patch. -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue11790 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue11790] transient failure in test_multiprocessing.WithProcessesTestCondition
Roundup Robot devnull@devnull added the comment: New changeset 88f1907fe312 by Antoine Pitrou in branch '3.2': Issue #11790: Fix sporadic failures in test_multiprocessing.WithProcessesTestCondition. http://hg.python.org/cpython/rev/88f1907fe312 New changeset 0ecfa2ce6561 by Antoine Pitrou in branch 'default': Issue #11790: Fix sporadic failures in test_multiprocessing.WithProcessesTestCondition. http://hg.python.org/cpython/rev/0ecfa2ce6561 -- nosy: +python-dev ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue11790 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue11790] transient failure in test_multiprocessing.WithProcessesTestCondition
Changes by Antoine Pitrou pit...@free.fr: -- resolution: - fixed stage: - committed/rejected status: open - closed versions: -Python 2.7, Python 3.1 ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue11790 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue11857] Hyphenate the argparse.rst file, patch added
Changes by Boštjan Mejak bostjan.me...@gmail.com: Removed file: http://bugs.python.org/file21682/argparse.patch ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue11857 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue11854] __or__ et al instantiate subclass of set without calling __init__
Santoso Wijaya santoso.wij...@gmail.com added the comment: Python 2.7.1 (r271:86832, Nov 27 2010, 17:19:03) [MSC v.1500 64 bit (AMD64)] on win32 Type help, copyright, credits or license for more information. class SetSub(set): ... def __init__(self, *args, **kwargs): ... print 'foo' ... set.__init__(self, *args, **kwargs) ... a = SetSub([2,7]) foo b = set([1,7]) a ^ b SetSub([1, 2]) Python 3.2 (r32:88445, Feb 20 2011, 21:30:00) [MSC v.1500 64 bit (AMD64)] on win 32 Type help, copyright, credits or license for more information. class SetSub(set): ... def __init__(self, *args, **kwargs): ... print('foo') ... set.__init__(self, *args, **kwargs) ... a = SetSub([2,7]) foo b = set([1,7]) a ^ b {1, 2} -- nosy: +santa4nt versions: +Python 2.7, Python 3.1, Python 3.2, Python 3.3 -Python 2.6 ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue11854 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue11854] __or__ et al instantiate subclass of set without calling __init__
Changes by Santoso Wijaya santoso.wij...@gmail.com: -- versions: -Python 3.1, Python 3.2, Python 3.3 ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue11854 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue11857] Hyphenate the argparse.rst file, patch added
Boštjan Mejak bostjan.me...@gmail.com added the comment: Added the new and improved patch. Now it is perfect. Please apply it. -- Added file: http://bugs.python.org/file21687/argparse.patch ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue11857 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue11701] email.parser.BytesParser().parse() closes file argument
Changes by R. David Murray rdmur...@bitdance.com: -- assignee: - r.david.murray ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue11701 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue1820] Enhance Object/structseq.c to match namedtuple and tuple api
Changes by Santoso Wijaya santoso.wij...@gmail.com: -- versions: +Python 3.3 -Python 3.2 ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue1820 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue11857] Hyphenate the argparse.rst file, patch added
Ezio Melotti ezio.melo...@gmail.com added the comment: Done in cc65cf9a9ce5, c33596e6f723, and fcce2f49ef6d. Thanks for the patch. -- assignee: docs@python - ezio.melotti nosy: +ezio.melotti resolution: - fixed stage: - committed/rejected status: open - closed ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue11857 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue11855] urlretrieve -- urlretrieve()
Changes by Ezio Melotti ezio.melo...@gmail.com: -- stage: - committed/rejected status: pending - closed ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue11855 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue11700] mailbox.py proxy updates
R. David Murray rdmur...@bitdance.com added the comment: Here's a patch that fixes the reported bug (calling close twice fails with an AttributeError) the simple way. Note that there was actually a test for the buggy behavior, which is rather odd considering that there is also a 'closed' method that would fail similarly if close was ever called. (The only use for the existing 'closed' method that I can see is to see if somebody else closed the file out from under the ProxyFile, a 'feature' that seems of dubious utility.) It seems clear to me that calling close more than once should be legal, so I fixed the test. closed will still report if the underlying file has been closed out from under ProxyFile. Steffen, I still don't understand what you are trying to achieve with your patches. I plan to close this issue by applying my patch. -- assignee: - r.david.murray Added file: http://bugs.python.org/file21688/mailbox_close_twice.patch ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue11700 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue10946] bdist doesn’t pass --skip-build on to subcommands
Wojciech Wojtyniak radi...@gmail.com added the comment: Could you please at least describe the test that you mentioned (link doesn't work). I added line that passes skip_build from bdist.py to its subcommands and it worked for me (at least for simple cases) - base.py is not called. If bdist wouldn't call any install_* in other way then via bdist_*, then we could use set_undefined_options in the last ones, but I'm not sure if it's safe. (If it is, I can provide appropriate patch.) Using set_undefined_options in install_* is definitely not safe, because it fails if parent process has not set skip_build. Also skip_build has to be set to None in install_* (set_... needs that to work) which obviously breaks it. Actually bdist_* sets skip_build like in my patch. Patch attached. Anyway test_skip_build() is still broken and needs a fix. -- keywords: +patch nosy: +radious Added file: http://bugs.python.org/file21689/skip_build.patch ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue10946 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue11859] test_interrupted_write_text() of test_io failed of Python 3.3 on FreeBSD 7.2
New submission from STINNER Victor victor.stin...@haypocalc.com: test_interrupted_write_text() of test_io failed of Python 3.3 on FreeBSD 7.2: --- [250/354] test_io Exception in thread Thread-1316: Traceback (most recent call last): File /usr/home/db3l/buildarea/3.x.bolen-freebsd7/build/Lib/threading.py, line 735, in _bootstrap_inner self.run() File /usr/home/db3l/buildarea/3.x.bolen-freebsd7/build/Lib/threading.py, line 688, in run self._target(*self._args, **self._kwargs) File /usr/home/db3l/buildarea/3.x.bolen-freebsd7/build/Lib/test/test_io.py, line 2630, in _read s = os.read(r, 1) OSError: [Errno 4] Interrupted system call Timeout (1:00:00)! Thread 0x28401040: File /usr/home/db3l/buildarea/3.x.bolen-freebsd7/build/Lib/test/test_io.py, line 2651 in check_interrupted_write File /usr/home/db3l/buildarea/3.x.bolen-freebsd7/build/Lib/test/test_io.py, line 2672 in test_interrupted_write_text File /usr/home/db3l/buildarea/3.x.bolen-freebsd7/build/Lib/unittest/case.py, line 387 in _executeTestPart File /usr/home/db3l/buildarea/3.x.bolen-freebsd7/build/Lib/unittest/case.py, line 442 in run File /usr/home/db3l/buildarea/3.x.bolen-freebsd7/build/Lib/unittest/case.py, line 494 in __call__ File /usr/home/db3l/buildarea/3.x.bolen-freebsd7/build/Lib/unittest/suite.py, line 105 in run File /usr/home/db3l/buildarea/3.x.bolen-freebsd7/build/Lib/unittest/suite.py, line 67 in __call__ File /usr/home/db3l/buildarea/3.x.bolen-freebsd7/build/Lib/unittest/suite.py, line 105 in run File /usr/home/db3l/buildarea/3.x.bolen-freebsd7/build/Lib/unittest/suite.py, line 67 in __call__ File /usr/home/db3l/buildarea/3.x.bolen-freebsd7/build/Lib/test/support.py, line 1078 in run File /usr/home/db3l/buildarea/3.x.bolen-freebsd7/build/Lib/test/support.py, line 1166 in _run_suite File /usr/home/db3l/buildarea/3.x.bolen-freebsd7/build/Lib/test/support.py, line 1192 in run_unittest File /usr/home/db3l/buildarea/3.x.bolen-freebsd7/build/Lib/test/test_io.py, line 2845 in test_main File ./Lib/test/regrtest.py, line 1041 in runtest_inner File ./Lib/test/regrtest.py, line 835 in runtest File ./Lib/test/regrtest.py, line 659 in main File ./Lib/test/regrtest.py, line 1619 in module *** Error code 1 Stop in /usr/home/db3l/buildarea/3.x.bolen-freebsd7/build. program finished with exit code 1 elapsedTime=8703.824572 --- http://www.python.org/dev/buildbot/all/builders/x86%20FreeBSD%207.2%203.x/builds/1695/steps/test/logs/stdio -- components: Tests messages: 133908 nosy: haypo, pitrou priority: normal severity: normal status: open title: test_interrupted_write_text() of test_io failed of Python 3.3 on FreeBSD 7.2 versions: Python 3.3 ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue11859 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue11859] test_interrupted_write_text() of test_io failed of Python 3.3 on FreeBSD 7.2
STINNER Victor victor.stin...@haypocalc.com added the comment: I already read somewhere that on FreeBSD, any thread can receive a signal, not only the main thread. I suppose that it should be the same on Linux, but Linux tries maybe to send a signal to the main thread if the main thread and other threads are calling a system call. In this case, _read thread gets the SIGARLM signal and so its os.read() system call is interrupted. It means that os.read() is blocked at least one second, whereas wio.write() is supposed to send data to unblock _read() thread. -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue11859 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue11859] test_interrupted_write_text() of test_io failed of Python 3.3 on FreeBSD 7.2
STINNER Victor victor.stin...@haypocalc.com added the comment: One solution to fix this problem is to use pthread_sigmask() on the _read() thread to not handle SIGARLM. For example, the faulthandler uses the following code to not handle any thread in its timeout thread: #ifdef HAVE_PTHREAD_H sigset_t set; /* we don't want to receive any signal */ sigfillset(set); #if defined(HAVE_PTHREAD_SIGMASK) !defined(HAVE_BROKEN_PTHREAD_SIGMASK) pthread_sigmask(SIG_SETMASK, set, NULL); #else sigprocmask(SIG_SETMASK, set, NULL); #endif #endif -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue11859 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue11854] __or__ et al instantiate subclass of set without calling __init__
Robert Burke sharpobj...@gmail.com added the comment: I've only observed this in 2.6. Does 2.6 not belong in the bug's versions list if 2.7 is also affected? -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue11854 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue11779] test_mmap timeout (30 min) on AMD64 Snow Leopard 3.x buildbot
STINNER Victor victor.stin...@haypocalc.com added the comment: Let's close this issue. I will reopen it if a timeout of 60 min was not the right choice to workaround this failure. -- resolution: - out of date status: open - closed ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue11779 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue9631] Python 2.7 installation issue for Linux gcc-4.1.0-3 (Fedora Core 5?)
Hans Lellelid h...@velum.net added the comment: I'm having apparently the same issue when attempting to build an RPM (based on EPEL 2.6.5 SPEC) on CentOS 5.5 i386. A straight configure/make/make install will work fine, but when editing Modules/Setup.dist to enabled *shared* (and then uncommenting the modules that I want to enable), and passing --enable-shared to configure, I now get the following error during make-install phase: PYTHONPATH=/var/tmp/python27-2.7.1-1.wt_el5-root-hans//usr/lib/python2.7 LD_LIBRARY_PATH=/home/hans/rpm/python27/Python-2.7.1: \ ./python -Wi -tt /var/tmp/python27-2.7.1-1.wt_el5-root-hans//usr/lib/python2.7/compileall.py \ -d /usr/lib/python2.7 -f \ -x 'bad_coding|badsyntax|site-packages|lib2to3/tests/data' \ /var/tmp/python27-2.7.1-1.wt_el5-root-hans//usr/lib/python2.7 Traceback (most recent call last): File /var/tmp/python27-2.7.1-1.wt_el5-root-hans//usr/lib/python2.7/compileall.py, line 17, in module import struct File /var/tmp/python27-2.7.1-1.wt_el5-root-hans/usr/lib/python2.7/struct.py, line 1, in module from _struct import * ImportError: No module named _struct I have cleaned out and rebuilt this many times. I'm going to continue digging to see if I can figure out how to get the the .so files in the right place (or put the right dir on the path). I'm also curious what changed from version 2.6 in this regard (and hopefully I'll figure it out with some more work). -- nosy: +hozn ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue9631 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue9041] raised exception is misleading
Meador Inge mead...@gmail.com added the comment: This problem still occurs in the main development branch. I think the 'PyErr_ExceptionMatches' check that Pauli suggested will work. The same problem exist for 'c_float', 'c_double', and 'c_longdouble'. Attached is a patch that fixes the issue and includes covering tests. Tested on OS X 10.6.5. -- assignee: theller - keywords: +patch nosy: +amaury.forgeotdarc, belopolsky, meador.inge -theller stage: - patch review versions: +Python 3.3 -Python 2.6 Added file: http://bugs.python.org/file21690/issue9041.patch ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue9041 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue9651] ctypes crash when writing zerolength string buffer to file
Meador Inge mead...@gmail.com added the comment: This crash still occurs in the main development branch and Amaury's patch still fixes the problem. I verified that all tests pass on OS X 10.6.5. It should be OK to commit. -- assignee: theller - nosy: +meador.inge -theller versions: +Python 2.7, Python 3.1, Python 3.2, Python 3.3 ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue9651 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue11860] reference 2.3 has text that runs past the page
New submission from Mike Kamermans niho...@gmail.com: page 8 for the python 3.2 refernce document (identifiers and keywords) has text that runs way past the page. This document (and probably every other document) should be run through LaTeX again with draft, to find all instances where text doesn't fit on the page, so that this can be fixed. -- assignee: docs@python components: Documentation messages: 133916 nosy: Mike.Kamermans, docs@python priority: normal severity: normal status: open title: reference 2.3 has text that runs past the page type: feature request versions: Python 3.2 ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue11860 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue11854] __or__ et al instantiate subclass of set without calling __init__
Raymond Hettinger raymond.hettin...@gmail.com added the comment: 2.6 is closed for anything except security patches at this point. 2.7 is only open for flat-out bugs, not API changes. So, we might be able to add code that could call the __init__ method (if it exists) whenever a new set is created, but we couldn't change whether __or__ returns a new set or frozenset instead of one of its subtypes. Existing, working code may reasonably rely on the current behavior of returning the subtype (FWIW, this also matches what was done in the original sets.py). -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue11854 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue9631] Python 2.7 installation issue for Linux gcc-4.1.0-3 (Fedora Core 5?)
Hans Lellelid h...@velum.net added the comment: Ok, I think I have tracked down the problem to a change that happened in site.py. In comparing against a build that worked fine for Python 2.6.5, I noticed that the Modules subdir (which contains the shared .so files) was present on the sys.path for Python 2.6 but not for 2.7. Digging deeper let me to the site.py module. In Python 2.7 the behavior was changed so that the Modules path element was removed from sys.path. This is probably best explained by the patch I applied to revert to 2.6.x behavior, which fixed the compile problem for me: --- Python-2.7.1/Lib/site.py2010-10-12 18:53:51.0 -0400 +++ Python-2.7.1/Lib/site.py.addbuilddir-revert 2011-04-16 23:03:47.0 -0400 @@ -122,7 +122,7 @@ s = build/lib.%s-%.3s % (get_platform(), sys.version) if hasattr(sys, 'gettotalrefcount'): s += '-pydebug' -s = os.path.join(os.path.dirname(sys.path.pop()), s) +s = os.path.join(os.path.dirname(sys.path[-1]), s) sys.path.append(s) Obviously I imagine there was a reason why this change was made, so the above patch is probably not an appropriate universal fix. I don't know anything about the original reasoning, but this change does seem to work for me on CentOS 5.5 now. Notably, the issue I'm describing doesn't appear to have anything to do with gcc. (Incidentally, I'm using gcc-4.1.2-48.el5.) -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue9631 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue11854] __or__ et al instantiate subclass of set without calling __init__
Raymond Hettinger raymond.hettin...@gmail.com added the comment: If some code were added to call __init__ for the new instance of a set/frozenset subclass, it would have to make an assumption that the method's signature allowed it to be called without any arguments. -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue11854 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue828450] sdist generates bad MANIFEST on Windows
Changes by higery shoulderhig...@gmail.com: Removed file: http://bugs.python.org/file21667/test_sdist.diff ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue828450 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue828450] sdist generates bad MANIFEST on Windows
higery shoulderhig...@gmail.com added the comment: It may be just necessary to hack the write_manifest funtion in sdist.py- replace all '\' in MANIFEST with '/', thus it will not have other bad side effects, for instance, it would not change the content of self.filelist and people can also use '/' in MANIFEST template file on windows as usual. -- Added file: http://bugs.python.org/file21691/change_path_separator_in_MANIFEST.patch ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue828450 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com