[issue10841] binary stdio

2011-01-05 Thread Antoine Pitrou
Antoine Pitrou added the comment: What are the results if, instead of piping through subprocess, you simply redirect stdout to a file (using "... > myfile.txt")? -- ___ Python tracker <http://bugs.pytho

[issue10841] binary stdio

2011-01-05 Thread Antoine Pitrou
Antoine Pitrou added the comment: > Actually, it seems like this "-u" behaviour, should simply be the > default for Python 3.x on Windows. There is nothing in "-u" which should explain the behaviour you're observing, so either way it's a bug. Making

[issue10840] pyarg_parsetuple docs and py_buffer

2011-01-05 Thread Antoine Pitrou
Antoine Pitrou added the comment: Done in 3.2 and 3.1. For 2.7 the structure of the doc page would lead to too much repetition IMO. -- resolution: -> fixed stage: needs patch -> committed/rejected status: open -> closed versions: -P

[issue10841] binary stdio

2011-01-05 Thread Antoine Pitrou
Antoine Pitrou added the comment: > Is there an easy way for me to find the code for -u? "-u" just passes 0 for the "buffering" argument to open() when creating stdout and stderr. Otherwise "buffering" equals -1. You can find equivalent code for open() in Lib/_

[issue5945] PyMapping_Check returns 1 for lists

2011-01-05 Thread Antoine Pitrou
Antoine Pitrou added the comment: Actually, making PyMapping_Check() more robust produces a test failure in test_builtin, because of the following code: # Verify locals stores (used by list comps) eval('[locals() for i in (2,3)]', g, d) eval('[locals(

[issue5945] PyMapping_Check returns 1 for lists

2011-01-06 Thread Antoine Pitrou
Antoine Pitrou added the comment: > Rather than introduce "fixes" that break code and hurt performance, I > think it would be better to deprecate PyMapping_Check() and wait for a > fast, clean C version of the ABCs (that is supposed to be our one > obvious way to do it).

[issue10841] binary stdio

2011-01-06 Thread Antoine Pitrou
Antoine Pitrou added the comment: > But there has to be special handling somewhere for opening std*, > because they are already open, unlike other files. That is no doubt > where the bug is. Can you point me at that code? See initstdio() in Python/py

[issue10841] binary stdio

2011-01-06 Thread Antoine Pitrou
Antoine Pitrou added the comment: > I suppose the FileIO in _io is next to look at, wherever it can be found. I don't get what you're looking for. FileIO is involved in both the buffered and unbuffered cases, so it shouldn't make a difference. In any case, please loo

[issue1677694] test_timeout refactoring

2011-01-06 Thread Antoine Pitrou
Antoine Pitrou added the comment: I adapted the patch for current py3k and committed it in r87786. Thank you for your patience. -- nosy: +pitrou resolution: -> fixed stage: patch review -> committed/rejected status: open -> closed _

[issue5945] PyMapping_Check returns 1 for lists

2011-01-06 Thread Antoine Pitrou
Antoine Pitrou added the comment: > > As for the "clean C version of the ABCs", > > I'm afraid we could wait quite a bit > > That may be true. I hope not. The ABCs were meant to solve exactly > this problem. At this point, I would rather ignore the p

[issue10841] binary stdio

2011-01-06 Thread Antoine Pitrou
Antoine Pitrou added the comment: Ok, actually it boils down to the following code in Modules/main.c: if (Py_UnbufferedStdioFlag) { #if defined(MS_WINDOWS) || defined(__CYGWIN__) _setmode(fileno(stdin), O_BINARY); _setmode(fileno(stdout), O_BINARY); #endif ... which

[issue10845] test_multiprocessing failure under Windows

2011-01-06 Thread Antoine Pitrou
New submission from Antoine Pitrou : This is under a Windows 7 VM. I don't understand what the assertion means: Z:\>__svn__\PCbuild\amd64\python_d.exe -m test -v test_multiprocessing == CPython 3.2b2+ (py3k, Jan 6 2011, 10:56:48) [MSC v.1500 64 bit (AMD64)] == Windows-7-6.1.7600 littl

[issue10845] test_multiprocessing failure under Windows

2011-01-06 Thread Antoine Pitrou
Changes by Antoine Pitrou : -- nosy: +brian.curtin ___ Python tracker <http://bugs.python.org/issue10845> ___ ___ Python-bugs-list mailing list Unsubscribe:

[issue10845] test_multiprocessing failure under Windows

2011-01-06 Thread Antoine Pitrou
Antoine Pitrou added the comment: Actually, it only happens if I use "-m test". If I use "-m test.regrtest" or "Lib/test/regrtest.py" instead, it works fine. -- nosy: +michael.foord, ncoghlan ___ Python tracker <

[issue10845] test_multiprocessing failure under Windows

2011-01-06 Thread Antoine Pitrou
Antoine Pitrou added the comment: (I guess this means that multiprocessing under Windows is not compatible with execution of a package through a __main__.py file...) -- ___ Python tracker <http://bugs.python.org/issue10

[issue10841] binary stdio

2011-01-06 Thread Antoine Pitrou
Antoine Pitrou added the comment: > So -u does do 2/3 of what my windows_binary() does :) Should I switch > my test case to use stderr to demonstrate that it doesn't help with > that? Well, judging by the history of this code, selectively putting -u in binary mode may be justifi

[issue10785] parser: store the filename as an unicode object

2011-01-06 Thread Antoine Pitrou
Changes by Antoine Pitrou : -- nosy: +benjamin.peterson ___ Python tracker <http://bugs.python.org/issue10785> ___ ___ Python-bugs-list mailing list Unsubscribe:

[issue4953] cgi module cannot handle POST with multipart/form-data in 3.0

2011-01-06 Thread Antoine Pitrou
Antoine Pitrou added the comment: > Haypo: I believe that the consensus we've come to is that you > shouldn't have to. FieldStorage should take a binary stream. So > should cgi.parse. If defaulting to sys.stdin, then if stdin is text, > they should turn it in to a bina

[issue2973] _ssl compiler warnings

2011-01-06 Thread Antoine Pitrou
Antoine Pitrou added the comment: I don't get any warnings with gcc -Wall and OpenSSL 1.0.x. -- nosy: +pitrou resolution: -> out of date status: open -> closed ___ Python tracker <http://bugs.python

[issue968063] Add fileinput.islastline()

2011-01-06 Thread Antoine Pitrou
Antoine Pitrou added the comment: Anyone wants to produce an up-to-date patch for py3k? -- keywords: +easy -patch nosy: +pitrou stage: -> needs patch type: -> feature request versions: +Python 3.3 -Python 2.6 ___ Python tracker

[issue10841] binary stdio

2011-01-06 Thread Antoine Pitrou
Changes by Antoine Pitrou : -- nosy: +benjamin.peterson ___ Python tracker <http://bugs.python.org/issue10841> ___ ___ Python-bugs-list mailing list Unsubscribe:

[issue3163] module struct support for ssize_t and size_t

2011-01-06 Thread Antoine Pitrou
Changes by Antoine Pitrou : -- versions: +Python 3.3 -Python 3.2 ___ Python tracker <http://bugs.python.org/issue3163> ___ ___ Python-bugs-list mailing list Unsub

[issue1158490] locale fails if LANGUAGE has multiple locales

2011-01-06 Thread Antoine Pitrou
Changes by Antoine Pitrou : -- nosy: +haypo stage: unit test needed -> patch review ___ Python tracker <http://bugs.python.org/issue1158490> ___ ___ Python-

[issue6269] threading documentation makes no mention of the GIL

2011-01-06 Thread Antoine Pitrou
Antoine Pitrou added the comment: Ok, done in r87792, r87793 and r87794, thank you. -- nosy: +pitrou resolution: -> fixed stage: -> committed/rejected status: open -> closed ___ Python tracker <http://bugs.python.o

[issue9909] request for calendar.dayofyear() function

2011-01-06 Thread Antoine Pitrou
Changes by Antoine Pitrou : -- nosy: +belopolsky ___ Python tracker <http://bugs.python.org/issue9909> ___ ___ Python-bugs-list mailing list Unsubscribe:

[issue4681] mmap offset should be off_t instead of ssize_t, and size calculation needs corrected

2011-01-06 Thread Antoine Pitrou
Changes by Antoine Pitrou : -- stage: -> patch review versions: +Python 3.2, Python 3.3 -Python 2.6 ___ Python tracker <http://bugs.python.org/issue4681> ___ _

[issue5369] __ppc__ macro checking is incorrect

2011-01-06 Thread Antoine Pitrou
Changes by Antoine Pitrou : -- resolution: -> duplicate status: open -> closed superseder: -> Wrong powerpc define in Python/ceval.c ___ Python tracker <http://bugs.python.o

[issue10655] Wrong powerpc define in Python/ceval.c

2011-01-06 Thread Antoine Pitrou
Antoine Pitrou added the comment: Issue5369 is a duplicate with the same patch. Dave, can you apply? -- assignee: -> dmalcolm ___ Python tracker <http://bugs.python.org/issu

[issue1521196] smtplib login fails with aol smtp server

2011-01-06 Thread Antoine Pitrou
Changes by Antoine Pitrou : -- nosy: +r.david.murray ___ Python tracker <http://bugs.python.org/issue1521196> ___ ___ Python-bugs-list mailing list Unsubscribe:

[issue3466] urllib2 should support HTTPS connections with client keys

2011-01-06 Thread Antoine Pitrou
Antoine Pitrou added the comment: In 3.2, you can instantiate a HTTPSHandler with a custom SSLContext, on which you can load your client cert: http://docs.python.org/dev/library/urllib.request.html#urllib.request.HTTPSHandler http://docs.python.org/dev/library/ssl.html

[issue6284] C/API PyErr_AsUnicode()

2011-01-06 Thread Antoine Pitrou
Changes by Antoine Pitrou : -- nosy: +haypo stage: -> patch review type: -> feature request versions: +Python 3.3 -Python 3.1 ___ Python tracker <http://bugs.python.org/

[issue1697943] msgfmt cannot cope with BOM

2011-01-06 Thread Antoine Pitrou
Changes by Antoine Pitrou : -- nosy: +haypo stage: unit test needed -> needs patch versions: +Python 2.7, Python 3.2, Python 3.3 -Python 2.6 ___ Python tracker <http://bugs.python.org/issue1

[issue3839] wsgi.simple_server resets 'Content-Length' header on empty content even if app defined it.

2011-01-06 Thread Antoine Pitrou
Antoine Pitrou added the comment: Fixed with tests in r87797 (3.2), r87798 (3.1) and r87799 (2.7). Thank you! -- nosy: +pitrou -BreamoreBoy resolution: -> fixed stage: unit test needed -> committed/rejected status: open -> closed ___ Pytho

[issue1615158] POSIX capabilities support

2011-01-06 Thread Antoine Pitrou
Changes by Antoine Pitrou : -- nosy: +pitrou, rosslagerwall ___ Python tracker <http://bugs.python.org/issue1615158> ___ ___ Python-bugs-list mailing list Unsub

[issue6064] Add "daemon" argument to threading.Thread constructor

2011-01-06 Thread Antoine Pitrou
Changes by Antoine Pitrou : -- assignee: jnoller -> stage: -> patch review type: behavior -> feature request versions: +Python 3.3 -Python 2.7, Python 3.2 ___ Python tracker <http://bugs.python.o

[issue8731] BeOS for 2.7 - add to unsupported

2011-01-06 Thread Antoine Pitrou
Antoine Pitrou added the comment: We should do a bit sweep over unsupported platforms in 3.3. -- nosy: +pitrou resolution: -> out of date status: open -> closed ___ Python tracker <http://bugs.python.org/

[issue4346] PyObject_CallMethod changes the exception message already set by PyObject_GetAttr

2011-01-06 Thread Antoine Pitrou
Changes by Antoine Pitrou : -- nosy: +benjamin.peterson -BreamoreBoy ___ Python tracker <http://bugs.python.org/issue4346> ___ ___ Python-bugs-list mailin

[issue9373] pulldom has low code coverage

2011-01-06 Thread Antoine Pitrou
Changes by Antoine Pitrou : -- nosy: +flox, loewis ___ Python tracker <http://bugs.python.org/issue9373> ___ ___ Python-bugs-list mailing list Unsubscribe:

[issue7858] os.utime(file, (0, 0, )) fails on on vfat, but doesn't fail immediately

2011-01-06 Thread Antoine Pitrou
Antoine Pitrou added the comment: Committed in r87802 (3.2), r87803 (3.1) and r87804 (2.7). Will watch the buildbots. -- resolution: -> fixed stage: needs patch -> committed/rejected status: open -> pending versions: -Python 2.6 _

[issue7858] os.utime(file, (0, 0, )) fails on on vfat, but doesn't fail immediately

2011-01-06 Thread Antoine Pitrou
Changes by Antoine Pitrou : -- status: pending -> closed ___ Python tracker <http://bugs.python.org/issue7858> ___ ___ Python-bugs-list mailing list Unsubscri

[issue1054041] Python doesn't exit with proper resultcode on SIGINT

2011-01-06 Thread Antoine Pitrou
Antoine Pitrou added the comment: - should KeyboardInterrupt always exit with SIGINT, or only if it was actually raised by a signal handler? - if _Py_UnhandledKeyboardInterrupt is defined in Modules/main.c but used in Python/pythonrun.c, can't it cause linker errors when embedding P

[issue2973] _ssl compiler warnings

2011-01-07 Thread Antoine Pitrou
Antoine Pitrou added the comment: Well, it merely means that OpenSSL has changed the const-ness of some of their APIs over time. As I said I see no warnings with the most recent OpenSSL versions. Buildbots will tell you the same story: for example, no warnings under OS X "Snow Leopard&q

[issue10851] further extend ssl SNI and ciphers API

2011-01-07 Thread Antoine Pitrou
Antoine Pitrou added the comment: > as a further extension to issue #5639 (sni) and issue #8322 this patch > provides the ability to set ciphers in the SSLContext.wrap_socket and > server_hostname in ssl.wrap_socket. This just makes all the ssl apis > look the same. Rest

[issue8109] Server-side support for TLS Server Name Indication extension

2011-01-07 Thread Antoine Pitrou
Antoine Pitrou added the comment: > Server side SNI is still missing. Right, re-opening. -- resolution: duplicate -> stage: -> needs patch status: closed -> open superseder: Support TLS SNI extension in ssl module -> title: Support for TLS Server Name Indication exte

[issue10853] SSL/TLS sni use in smtp, pop, imap, nntp, ftp client libs by default

2011-01-07 Thread Antoine Pitrou
Antoine Pitrou added the comment: Duplicate posting of #10852. -- resolution: -> duplicate status: open -> closed superseder: -> SSL/TLS sni use in smtp,pop,imap,nntp,ftp client libs by default ___ Python tracker <http://bug

[issue10852] SSL/TLS sni use in smtp, pop, imap, nntp, ftp client libs by default

2011-01-07 Thread Antoine Pitrou
Antoine Pitrou added the comment: Oops, I hadn't noticed you had closed it. -- nosy: +pitrou resolution: duplicate -> status: closed -> open ___ Python tracker <http://bugs.python.

[issue10858] Make source code links less proeminent

2011-01-07 Thread Antoine Pitrou
New submission from Antoine Pitrou : Reading library source code will only be enlightening to expert users, since most modules are not academic but real-world implementations, with all the complications it entails. Therefore, putting a link at the top of module sections is only confusing for

[issue10852] SSL/TLS sni use in smtp, pop, imap, nntp, ftp client libs by default

2011-01-07 Thread Antoine Pitrou
Antoine Pitrou added the comment: I understand this patch relies on #10851. As I said there, I would rather have SSLContext become the primary API, and the stdlib standardize on it. Part of the stdlib, as you have witnessed, already allows the user to pass a custom SSLContext, which is very

[issue8808] imaplib should support SSL contexts

2011-01-07 Thread Antoine Pitrou
Changes by Antoine Pitrou : -- stage: -> needs patch versions: +Python 3.3 -Python 3.2 ___ Python tracker <http://bugs.python.org/issue8808> ___ ___ Python-

[issue8809] smptlib should support SSL contexts

2011-01-07 Thread Antoine Pitrou
Changes by Antoine Pitrou : -- stage: -> needs patch versions: +Python 3.3 -Python 3.2 ___ Python tracker <http://bugs.python.org/issue8809> ___ ___ Python-

[issue10808] ssl unwrap fails with Error 0

2011-01-07 Thread Antoine Pitrou
Antoine Pitrou added the comment: As we discussed on IRC, there are two things here: - unwrap() can give an error because it tries to shutdown the SSL layer cleanly, and the other side doesn't support it or is already closed; unwrap() is useful mostly if you plan to use the clear-text

[issue9090] Error code 10035 calling socket.recv() on a socket with a timeout (WSAEWOULDBLOCK - A non-blocking socket operation could not be completed immediately)

2011-01-07 Thread Antoine Pitrou
Antoine Pitrou added the comment: I will not bother backporting myself but an other core developer can do it if (s)he desires. -- ___ Python tracker <http://bugs.python.org/issue9

[issue10808] ssl unwrap fails with Error 0

2011-01-07 Thread Antoine Pitrou
Antoine Pitrou added the comment: > "This information" being no information, is that really all you can get out > of OpenSSL? Well the situation as the same as a system call which would return failure but leave errno 0 (except that OpenSSL has its own kind-of-errnos).

[issue10859] Is GeneratorContextManager public?

2011-01-07 Thread Antoine Pitrou
New submission from Antoine Pitrou : contextlib.GeneratorContextManager doesn't have an underscore but it's not documented either. Something has to be done (I would say make it private). -- components: Library (Lib) messages: 125683 nosy: michael.foord, ncoghlan, pitro

[issue10859] Is GeneratorContextManager public?

2011-01-07 Thread Antoine Pitrou
Antoine Pitrou added the comment: > There was a discussion on python-dev about naming conventions in the > standard library. There was no clear consensus that everything > non-public should start with an underscore. Several developers thought > that merely being undocumented or no

[issue10861] urllib2 sporadically falsely claims infinite redirect

2011-01-07 Thread Antoine Pitrou
Antoine Pitrou added the comment: Apparently, it's a problem on bankofamerica.com: $ curl -v https://www.bankofamerica.com/ * About to connect() to www.bankofamerica.com port 443 (#0) * Trying 171.161.148.173... connected * Connected to www.bankofamerica.com (171.161.148.173) port 44

[issue10861] urllib2 sporadically falsely claims infinite redirect

2011-01-07 Thread Antoine Pitrou
Antoine Pitrou added the comment: Actually, perhaps the redirection loop would stop if we would send back those cookies which the server sends us. So perhaps it's a feature request rather. (but this still strikes me as a very poor use of

[issue10858] Make source code links less proeminent

2011-01-07 Thread Antoine Pitrou
Antoine Pitrou added the comment: > The goal is to reacquaint people with the source as an adjunct to the > docs. The phrase use-the-source-luke used to be common in the python > community but now many devs don't seem to be able to readily access > the source (with it tucked

[issue10858] Make source code links less prominent

2011-01-07 Thread Antoine Pitrou
Antoine Pitrou added the comment: > I have a few suggestions on how to make these links more useful: The question is not how they could be more useful, but *whether* they are useful at all. An user skilled enough to read the source code is probably skilled enough not to require a prominen

[issue8020] Crash in Py_ADDRESS_IN_RANGE macro

2011-01-07 Thread Antoine Pitrou
Antoine Pitrou added the comment: I've committed Matt's patch in r87835 (3.2), r87836 (3.1) and r87837 (2.7). Thank you for contributing! -- resolution: -> fixed stage: needs patch -> committed/rejected status: open -> closed ver

[issue8844] Condition.wait() doesn't raise KeyboardInterrupt

2011-01-07 Thread Antoine Pitrou
Antoine Pitrou added the comment: Well, since #10720 exists, while do you reopen this one? -- ___ Python tracker <http://bugs.python.org/issue8844> ___ ___ Pytho

[issue10859] Is GeneratorContextManager public?

2011-01-08 Thread Antoine Pitrou
Antoine Pitrou added the comment: Ok, done in r87860. -- resolution: -> fixed stage: -> committed/rejected status: open -> closed ___ Python tracker <http://bugs.python.or

[issue10849] Backport test/__main__

2011-01-08 Thread Antoine Pitrou
Antoine Pitrou added the comment: A backport would be more attractive if the Windows issue was fixed first... (and I don't care about the "policy" here: anything which makes testing easier is good IMO, and we have routinely backported tests as mentioned by someone else)

[issue2650] re.escape should not escape underscore

2011-01-08 Thread Antoine Pitrou
Antoine Pitrou added the comment: James, could you propose a proper patch? Even better if you also give a couple of timing results, just for the record? -- versions: +Python 3.2 -Python 2.7, Python 3.1 ___ Python tracker <http://bugs.python.

[issue10174] multiprocessing expects sys.stdout to have a fileno/close method.

2011-01-08 Thread Antoine Pitrou
Antoine Pitrou added the comment: Ok, closing then. -- nosy: +pitrou resolution: -> duplicate status: open -> closed superseder: -> multiprocessing.process using os.close(sys.stdin.fileno) instead of sys.stdin.close() ___ Python track

[issue10834] Python 2.7 x86 IDLE fails to run in Windows 7

2011-01-08 Thread Antoine Pitrou
Changes by Antoine Pitrou : -- nosy: +loewis ___ Python tracker <http://bugs.python.org/issue10834> ___ ___ Python-bugs-list mailing list Unsubscribe:

[issue3132] implement PEP 3118 struct changes

2011-01-08 Thread Antoine Pitrou
Changes by Antoine Pitrou : -- assignee: meador.inge -> mark.dickinson stage: needs patch -> patch review versions: +Python 3.3 -Python 3.2 ___ Python tracker <http://bugs.python.org/

[issue10868] ABCMeta.register() should work as a decorator

2011-01-08 Thread Antoine Pitrou
Antoine Pitrou added the comment: Looks like a good idea to me. -- nosy: +benjamin.peterson, gvanrossum, pitrou stage: -> patch review ___ Python tracker <http://bugs.python.org/issu

[issue10872] Add mode to TextIOWrapper repr

2011-01-09 Thread Antoine Pitrou
Changes by Antoine Pitrou : -- components: +IO nosy: +amaury.forgeotdarc, benjamin.peterson type: -> feature request ___ Python tracker <http://bugs.python.org/issu

[issue9504] signal.signal/signal.alarm not working as expected

2011-01-09 Thread Antoine Pitrou
Antoine Pitrou added the comment: Charles-François' analysis seems to be right. Note that the actual issue here is that read() always succeeds, returning a partial result (because you're executing a command, 'find /', which outputs a lot of data). If read() were interru

[issue10872] Add mode to TextIOWrapper repr

2011-01-09 Thread Antoine Pitrou
Antoine Pitrou added the comment: Here is a patch. -- keywords: +patch Added file: http://bugs.python.org/file20328/textiorepr.patch ___ Python tracker <http://bugs.python.org/issue10

[issue10872] Add mode to TextIOWrapper repr

2011-01-09 Thread Antoine Pitrou
Antoine Pitrou added the comment: Committed in r87897. Left open for backport. -- assignee: pitrou -> resolution: -> accepted stage: -> committed/rejected type: feature request -> behavior versions: +Python 2.7, Python 3.1 -Python 3.2 __

[issue9504] signal.signal/signal.alarm not working as expected

2011-01-09 Thread Antoine Pitrou
Antoine Pitrou added the comment: > Attached is a tentative patch: it checks for pending signals inside > _bufferedreader_read_generic, fileio_readall, and rawiobase_readall. > I tested quickly on regular files and on pipes, and handlers are now > called on time. As a an obvious

[issue10116] Sporadic failures in test_urllibnet

2011-01-09 Thread Antoine Pitrou
Antoine Pitrou added the comment: There are still sporadic failures: http://www.python.org/dev/buildbot/all/builders/AMD64%20Leopard%203.x/builds/684/steps/test/logs/stdio Of course, it seems to be because of stupid urllib wrapping the socket.error inside an IOError: Traceback (most recent

[issue10876] Zipfile crashes when zip password is set to 610/844/numerous other numbers

2011-01-10 Thread Antoine Pitrou
Antoine Pitrou added the comment: Well, the password-checking scheme uses a one-byte check against the zip header for consistency. So there is a (near) 1/256 chance of false positives, that is of bad passwords mistakenly detected as good; then the ZipFile class proceeds with unarchiving and

[issue10866] Add sethostname()

2011-01-10 Thread Antoine Pitrou
Changes by Antoine Pitrou : -- nosy: +pitrou stage: -> patch review type: -> feature request ___ Python tracker <http://bugs.python.org/issue10866> ___ ___

[issue2320] Race condition in subprocess using stdin

2011-01-10 Thread Antoine Pitrou
Antoine Pitrou added the comment: I confirm that it works reliably under 3.2, while it hangs as reliably under 2.7 and 3.1. Since fixing involves a C extension that is too heavy to backport to bugfix branches, I suggest closing. By the way: triagers, please don't set stage to "

[issue10820] 3.2 Makefile changes for versioned scripts break OS X framework installs

2011-01-10 Thread Antoine Pitrou
Antoine Pitrou added the comment: Looks like an issue in test_site rather than site.py itself (which has dedicated code to add a third site directory under framework builds). The test_site failure is not enough to hold the release, IMO. Given Ronald's absence, I think Ned could

[issue10784] os.getpriority() and os.setpriority()

2011-01-10 Thread Antoine Pitrou
Changes by Antoine Pitrou : -- stage: -> patch review ___ Python tracker <http://bugs.python.org/issue10784> ___ ___ Python-bugs-list mailing list Unsubscri

[issue10882] Add os.sendfile()

2011-01-10 Thread Antoine Pitrou
Antoine Pitrou added the comment: > Tested on Linux & FreeBSD - it should work on solaris but since it > needs to link with the sendfile library and I have no idea how to link > the posix module with the sendfile library only on Solaris, i couldn't > test it. Since the p

[issue10394] subprocess Popen deadlock

2011-01-10 Thread Antoine Pitrou
Antoine Pitrou added the comment: Ok, so let's close the issue. The fix can't reasonably be backported since it involves a whole new C extension and a rather large chunk of new code. -- nosy: +gregory.p.smith resolution: -> out of date status: open -> closed versio

[issue9124] Mailbox module should use binary I/O, not text I/O

2011-01-12 Thread Antoine Pitrou
Antoine Pitrou added the comment: The aforementioned python-dev thread (available at http://mail.python.org/pipermail/python-dev/2010-June/101186.html ) explains things quite well. The mailbox module needs to be modified to use binary I/O, both for functionality and for speed. Right now, I

[issue9880] Python 2.7 Won't Build: SystemError: unknown opcode

2011-01-12 Thread Antoine Pitrou
Antoine Pitrou added the comment: [...] > > gcc-4.6 -O1 -ftree-vectorize > - > 0x00480991 <+5041>: mov%eax,%ecx > 0x00480993 <+5043>: sub%edx,%ecx > 0x00480995 <+5045>: mov%ecx,(%r12

[issue1488934] file.write + closed pipe = no error

2011-01-12 Thread Antoine Pitrou
Antoine Pitrou added the comment: Agreed with Charles-François, this is normal behaviour since the bytes written on stdout are buffered (up to a certain size). If calling flush() doesn't solve the issue, please reopen the issue. -- resolution: -> invalid status: open -

[issue10896] trace module compares directories as strings (--ignore-dir)

2011-01-12 Thread Antoine Pitrou
Changes by Antoine Pitrou : -- stage: -> patch review type: -> behavior ___ Python tracker <http://bugs.python.org/issue10896> ___ ___ Python-bugs-list

[issue1488934] file.write + closed pipe = no error

2011-01-12 Thread Antoine Pitrou
Antoine Pitrou added the comment: > msg28537 shows a version with flush, and says that it fails I cannot reproduce. Either with Python 2.5.2 (!), 2.7 or 3.2, on a remote Debian system. Even using "kill -9" on the local ssh process does shut down the remote Python process. If

[issue10822] test_getgroups failure under Solaris

2011-01-12 Thread Antoine Pitrou
Antoine Pitrou added the comment: Thanks for the patch! Committed in r87958 (3.2), r87959 (3.1) and r87961 (2.7). -- resolution: -> fixed stage: needs patch -> committed/rejected status: open -> closed ___ Python tracker <http://bug

[issue10897] UNIX mmap unnecessarily dup() file descriptor

2011-01-12 Thread Antoine Pitrou
Antoine Pitrou added the comment: The problem is that it's a change in semantics. So it definitely can't be backported to the bugfix branches, nor committed into 3.2 which is in feature freeze now. The question is which behaviour is the most expected by users of the module. I'

[issue10894] Making stdlib APIs private

2011-01-12 Thread Antoine Pitrou
Antoine Pitrou added the comment: My take on this: - adding underscores to locally-defined private functions is good. +1 - -0.5 on "from warnings import warn as _warn"; it's useless complication, users should be able to realize warn() is a public API of the warnings module, not

[issue10894] Making stdlib APIs private

2011-01-12 Thread Antoine Pitrou
Antoine Pitrou added the comment: Oh, by the way, it can be good to check that the APIs are not used too widely. Example for such a query: http://www.google.com/codesearch?q=lang%3Apython%20do_longs&hl=fr (in this case, it's clear that only copies of the stdlib reference that

[issue10855] wave.Wave_read.close() doesn't release file

2011-01-12 Thread Antoine Pitrou
Antoine Pitrou added the comment: Agreed with Georg. No OS resource is leaking if the file is explicitly closed (since it releases the underlying file descriptor). That the Python "file object" is still attached somewhere is of secondary importance. -- nos

[issue10855] wave.Wave_read.close() doesn't release file

2011-01-12 Thread Antoine Pitrou
Antoine Pitrou added the comment: > It allows garbage collection to close the file object if there are no > more references to it. This is a very bad policy to begin with. Garbage collection can be delayed for a number of reasons: - someone might be running your program on a

[issue2650] re.escape should not escape underscore

2011-01-12 Thread Antoine Pitrou
Antoine Pitrou added the comment: > As James said I have written the patch using only regular expressions . > This is going to be my first patch . I need help writing the test for it You will find the current tests in Lib/test/test_re.py. To execute them, run: $ ./python -m test.regrt

[issue10899] No function type annotations in the standard library

2011-01-12 Thread Antoine Pitrou
Antoine Pitrou added the comment: > On the other hand, having this precedent might give passers-by and > perhaps future stdlib developers the idea that a convention has been > adopted by the stdlib Could we simply state in PEP 8 that annotations have no official meaning and th

[issue7322] Socket timeout can cause file-like readline() method to lose data

2011-01-13 Thread Antoine Pitrou
Antoine Pitrou added the comment: This is an interesting approach. The problem is that AFAICT the issue is not limited to readline. If you call e.g. read(1) and the socket times out after having returned the first 5000 bytes, then those 5000 bytes might get lost as well (depending on

[issue7322] Socket timeout can cause file-like readline() method to lose data

2011-01-13 Thread Antoine Pitrou
Antoine Pitrou added the comment: By the way, I recently fixed the makefile() documentation: “The socket must be in blocking mode; it can have a timeout, but the file object’s internal buffer may end up in a inconsistent state if a timeout occurs.” (in http://docs.python.org/dev/library

[issue10577] (Fancy) URL opener stuck when trying to open redirected url

2011-01-13 Thread Antoine Pitrou
Antoine Pitrou added the comment: Ok, closing as duplicate. -- resolution: -> duplicate status: open -> closed superseder: -> urllib.request.urlretrieve hangs ___ Python tracker <http://bugs.python.or

[issue8035] urllib.request.urlretrieve hangs waiting for connection close after a redirect

2011-01-13 Thread Antoine Pitrou
Antoine Pitrou added the comment: issue10577 is a duplicate. See an URL allowing reproducing in msg122831. -- nosy: +pitrou priority: high -> normal stage: unit test needed -> needs patch title: urllib.request.urlretrieve hangs -> urllib.request.urlretrieve hangs wa

[issue7322] Socket timeout can cause file-like readline() method to lose data

2011-01-13 Thread Antoine Pitrou
Antoine Pitrou added the comment: > """Generally there is no guarantee that a buffered object works > "properly" when the raw IO object raises some exception > intermittently""" > > I disagree. EINTR is a classic case of this and is some

[issue7322] Socket timeout can cause file-like readline() method to lose data

2011-01-13 Thread Antoine Pitrou
Antoine Pitrou added the comment: > > That's my opinion too. So, instead, of doing the above surgery inside > > the IO stack, the SocketIO layer could detect the timeout and disallow > > further access. What do you think? > > So after a timeout occurs the

<    30   31   32   33   34   35   36   37   38   39   >