[issue11459] Python select.select does not correctly report read readyness
Gregory P. Smith g...@krypto.org added the comment: yeah i figured importing io from os at the top level might be a problem. it is not important for the default to be that exact value, even something safely on the small side like 512 will work. but we could just have the default be set in the code by doing the 'import io' at os.popen() runtime. -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue11459 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue11567] http.server error message format
Gennadiy Zlobin gennad.zlo...@gmail.com added the comment: Hi guys, this is my first patch for the Python interpreter. Hope it is ok, but if it is not, be sure to comment and I'll fix it ASAP -- keywords: +patch Added file: http://bugs.python.org/file21262/11567.patch ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue11567 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue11442] list_directory() in SimpleHTTPServer.py should add charset=... to Content-type header
Roundup Robot devnull@devnull added the comment: New changeset e9724d7abbc2 by Senthil Kumaran in branch '2.5': Fix issue11442 - Add a charset parameter to the Content-type to avoid XSS attacks. http://hg.python.org/cpython/rev/e9724d7abbc2 -- nosy: +python-dev ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue11442 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue11581] buildbot error when pushing to 2.5 branch?
New submission from Senthil Kumaran orsent...@gmail.com: When pushed a change to 2.5 branch, I got an error, which I think has to do with buildbot not available for 2.5 codeline. It asked me to notify the tracker and here it is. remote: state = method(*args, **kw) remote: File /data/buildbot/master/master.cfg, line 87, in perspective_addChange remote: changedict['category'] = branch_to_category[changedict['branch']] remote: exceptions.KeyError: '2.5' remote: ] remote: sent email to roundup at rep...@bugs.python.org -- files: bb-error.txt messages: 131229 nosy: orsenthil, python-dev priority: normal severity: normal status: open title: buildbot error when pushing to 2.5 branch? Added file: http://bugs.python.org/file21263/bb-error.txt ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue11581 ___pushing to ssh://h...@hg.python.org/cpython searching for changes remote: adding changesets remote: adding manifests remote: adding file changes remote: added 4 changesets with 2 changes to 1 files remote: change(s) NOT sent, something went wrong: remote: [Failure instance: Traceback from remote host -- Traceback (most recent call last): remote: File /usr/lib/python2.6/dist-packages/twisted/spread/banana.py, line 153, in gotItem remote: self.callExpressionReceived(item) remote: File /usr/lib/python2.6/dist-packages/twisted/spread/banana.py, line 116, in callExpressionReceived remote: self.expressionReceived(obj) remote: File /usr/lib/python2.6/dist-packages/twisted/spread/pb.py, line 514, in expressionReceived remote: method(*sexp[1:]) remote: File /usr/lib/python2.6/dist-packages/twisted/spread/pb.py, line 826, in proto_message remote: self._recvMessage(self.localObjectForID, requestID, objectID, message, answerRequired, netArgs, netKw) remote: --- exception caught here --- remote: File /usr/lib/python2.6/dist-packages/twisted/spread/pb.py, line 840, in _recvMessage remote: netResult = object.remoteMessageReceived(self, message, netArgs, netKw) remote: File /usr/lib/python2.6/dist-packages/twisted/spread/pb.py, line 225, in perspectiveMessageReceived remote: state = method(*args, **kw) remote: File /data/buildbot/master/master.cfg, line 87, in perspective_addChange remote: changedict['category'] = branch_to_category[changedict['branch']] remote: exceptions.KeyError: '2.5' remote: ] remote: sent email to roundup at rep...@bugs.python.org remote: notified python-check...@python.org of incoming changeset e9724d7abbc2 remote: notified python-check...@python.org of incoming changeset 8cdb95cf096e remote: notified python-check...@python.org of incoming changeset 6cd7de9deb1a remote: notified python-check...@python.org of incoming changeset 1148131b1099 ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue11582] Boilerplate code replaced in Python/ceval.c
New submission from knickerkicker knicker.kic...@gmail.com: Replaced boilerplate implementations of several BINARY_* and INPLACE_* opcodes with two macros. The result shaves off 154 lines from Python/ceval.c. -- components: Interpreter Core files: 20110317_ceval.patch keywords: patch messages: 131230 nosy: knicker.kicker priority: normal severity: normal status: open title: Boilerplate code replaced in Python/ceval.c versions: Python 3.1, Python 3.2, Python 3.3, Python 3.4 Added file: http://bugs.python.org/file21264/20110317_ceval.patch ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue11582 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue11442] list_directory() in SimpleHTTPServer.py should add charset=... to Content-type header
Senthil Kumaran orsent...@gmail.com added the comment: Fixed in all the relevant code lines. -- assignee: - orsenthil priority: release blocker - resolution: - fixed stage: needs patch - committed/rejected status: open - closed ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue11442 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue11088] IDLE on OS X with Cocoa Tk 8.5 can hang waiting on input / raw_input
Ned Deily n...@acm.org added the comment: I don't have any better suggestions at the moment so let's go with it. Perhaps we'll get more insight to the root cause later. -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue11088 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue11055] OS X IDLE 3.2 Save As menu accelerator opens two Save windows
Ned Deily n...@acm.org added the comment: The actual unwanted event is being generated as a result of the menu add command accelerator. You can see that by playing with Wish. set w .menu catch {destroy $w} toplevel $w wm title $w Menu Shift menu $w.menu -tearoff 0 set m $w.menu.basic $w.menu add cascade -label Basic -menu $m -underline 0 menu $m -tearoff 0 $m add command -label Test \ -command puts command -accelerator Command-Shift-A bind $w Command-Shift-A puts bind $w configure -menu $w.menu It appears that there is a bug in the Cocoa Tk right now where accelerators with Shift (at least) in them are not being properly ignored by Tk. In the Carbon Tk and the X11 Tk, I believe the only effect of the accelerator definitions on the add command is to be used to create the shortcut characters displayed in the menu entry. However, apparently a side effect of using the Cocoa APIs is that the menu definitions now cause notifications back into Tk which are not supposed to be translated into Tcl/Tk events back to the app. For some reason, the shift ones are not being ignored. https://github.com/das/tcltk/blob/master/tk/macosx/tkMacOSXMenu.c Also, it seems that with all three of the Tk implementations (Carbon, X11, and Cocoa), using a capital letter for the menu accelerator implies Shift. -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue11055 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue4114] struct returns incorrect 4 byte float
Mark Dickinson dicki...@gmail.com added the comment: I don't think this needs to be documented beyond the limitations of floating-point that are already documented in the tutorial. It's the obvious behaviour: double to float (when packing) converts to the nearest float; the float to double conversion is exact. -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue4114 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue4114] struct returns incorrect 4 byte float
Mark Dickinson dicki...@gmail.com added the comment: [Robert] I have to disagree. It seems entirely reasonable to expect that unpack should return the same value passed to pack. Robert: notice that a *Python* float (a *64-bit* C double internally) is here being stored as a *32-bit* float, losing precision. So no, it's not at all reasonable to expect that unpack should return the same value passed to pack---it's mathematically impossible for it to do so. There are (around) 2**64 distinct Python floats, and only 2**32 ways to pack them using 'f'. When packing / unpacking using 'd', it *is* reasonable to expect the value to be recovered exactly, and as far as I know that's always what happens (barring peculiarities like NaN payloads not being reproduced exactly). -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue4114 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue11567] http.server error message format
Roundup Robot devnull@devnull added the comment: New changeset db4967095f10 by Senthil Kumaran in branch '3.2': Fix issue11567: http.server DEFAULT_ERROR_MESSAGE format. Patch by Gennadiy Zlobin. http://hg.python.org/cpython/rev/db4967095f10 -- nosy: +python-dev ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue11567 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue11567] http.server error message format
Senthil Kumaran orsent...@gmail.com added the comment: Fixed in 3.3 and 3.2. -- resolution: - fixed status: open - closed ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue11567 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue11583] os.path.isdir() is slow on windows
New submission from Eli Bendersky eli...@gmail.com: Report here: http://stackoverflow.com/questions/5316928/python-os-path-isdir-is-slow-on-windows It could be a problem with Windows itself, but I'm opening this to keep track of the issue, just to be on the safe side. -- components: Library (Lib) messages: 131238 nosy: brian.curtin, eli.bendersky, tim.golden priority: normal severity: normal status: open title: os.path.isdir() is slow on windows type: performance versions: Python 2.7, Python 3.1, Python 3.2, Python 3.3 ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue11583 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue11557] Increase coverage in logging module
Changes by Gennadiy Zlobin gennad.zlo...@gmail.com: -- nosy: +gennad ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue11557 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue4492] httplib code thinks it closes connection, but does not
Changes by Gennadiy Zlobin gennad.zlo...@gmail.com: -- nosy: +gennad ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue4492 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue11583] os.path.isdir() is slow on windows
Martin v. Löwis mar...@v.loewis.de added the comment: How do you expect this to be resolved? Or will it stay open until Microsoft improves the NTFS performance? -- nosy: +loewis ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue11583 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue11568] docstring of select.epoll.register() is wrong
Changes by Gennadiy Zlobin gennad.zlo...@gmail.com: -- assignee: - docs@python components: +Documentation nosy: +docs@python type: - behavior ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue11568 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue11568] docstring of select.epoll.register() is wrong
Gennadiy Zlobin gennad.zlo...@gmail.com added the comment: The patch fixes the docstring -- keywords: +patch nosy: +gennad Added file: http://bugs.python.org/file21265/11568.patch ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue11568 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue11583] os.path.isdir() is slow on windows
Eli Bendersky eli...@gmail.com added the comment: On Thu, Mar 17, 2011 at 12:46, Martin v. Löwis rep...@bugs.python.orgwrote: I opened this in order not to forget to look at the implementation of isdir on windows, making sure it's the most optimal thing we can do. If you know it is, the issue can be closed as far as I'm concerned. -- Added file: http://bugs.python.org/file21266/unnamed ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue11583 ___div dir=ltrbrbrdiv class=gmail_quoteOn Thu, Mar 17, 2011 at 12:46, Martin v. Löwis span dir=ltrlt;a href=mailto:rep...@bugs.python.org;rep...@bugs.python.org/agt;/span wrote:brblockquote class=gmail_quote style=margin: 0pt 0pt 0pt 0.8ex; border-left: 1px solid rgb(204, 204, 204); padding-left: 1ex; br Martin v. Löwis lt;a href=mailto:mar...@v.loewis.de;mar...@v.loewis.de/agt; added the comment:br br How do you expect this to be resolved? Or will it stay open until Microsoft improves the NTFS performance?br br/blockquote/divbrI opened this in order not to forget to look at the implementation of isdir on windows, making sure it#39;s the most optimal thing we can do. If you know it is, the issue can be closed as far as I#39;m concerned.br br/div ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue11583] os.path.isdir() is slow on windows
Changes by SilentGhost ghost@gmail.com: Removed file: http://bugs.python.org/file21266/unnamed ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue11583 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue11584] email/header.py: missing str()ification, and bogus encode()s
New submission from Steffen Daode Nurpmeso sdao...@googlemail.com: My minimal failing test case dragged yet another EMAIL error to the light!!! Man, man, man - it's really great that QNX fund money so that you have the time to fix this broken thing! It's got washed away, but http://bugs.python.org/file21210/email_header.diff can be used on top of 42cd61b96e54 to fix the following: __ Traceback (most recent call last): [FOREIGN CODE] File /Users/steffen/usr/bin/s-postman.py, line 1765, in _bewitch_msg self._msg[n] = email.header.make_header(email.header.decode_header(b)) File /Users/steffen/usr/opt/py3k/lib/python3.3/email/header.py, line 73, in decode_header if not ecre.search(header): Exception: TypeError: expected string or buffer __ However, if that's patched in, we end up here __ Traceback (most recent call last): [FOREIGN CODE] File /Users/steffen/usr/bin/s-postman.py, line 1765, in _bewitch_msg self._msg[n] = email.header.make_header(email.header.decode_header(b)) File /Users/steffen/usr/opt/py3k/lib/python3.3/email/header.py, line 154, in make_header h.append(s, charset) File /Users/steffen/usr/opt/py3k/lib/python3.3/email/header.py, line 278, in append s.encode(output_charset, errors) Exception: UnicodeEncodeError: 'ascii' codec can't encode character '\ufffd' in position 7: ordinal not in range(128) __ Let me know if you want that '456943 17 Mar 12:51 rdm-postman.tbz' thing, it's waiting for you. It contains a digest mbox, a config and the patched S-Postman. Maybe i can strip it to 42 if i spend some more time on it. -- components: Library (Lib) messages: 131242 nosy: r.david.murray, sdaoden priority: normal severity: normal status: open title: email/header.py: missing str()ification, and bogus encode()s versions: Python 3.3 ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue11584 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue11580] Add width and precision formatters to PyBytes_FromFormatV()
Changes by Amaury Forgeot d'Arc amaur...@gmail.com: -- assignee: - haypo nosy: +haypo ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue11580 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue1628484] Python 2.5 64 bit compile fails on Solaris 10/gcc 4.1.1
Changes by Jesús Cea Avión j...@jcea.es: -- nosy: +jcea ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue1628484 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue1676121] Problem linking to readline lib on x86(64) Solaris
Changes by Jesús Cea Avión j...@jcea.es: -- nosy: +jcea ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue1676121 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue1733484] Solaris 64 bit LD_LIBRARY_PATH_64 needs to be set
Changes by Jesús Cea Avión j...@jcea.es: -- nosy: +jcea ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue1733484 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue847812] 64 bit solaris versus /usr/local/lib
Changes by Jesús Cea Avión j...@jcea.es: -- nosy: +jcea ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue847812 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue1294959] Problems with /usr/lib64 builds.
Changes by Jesús Cea Avión j...@jcea.es: -- nosy: +jcea ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue1294959 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue1681333] email.header unicode fix
R. David Murray rdmur...@bitdance.com added the comment: Yes, I can well understand that feeling. I've only relatively recently taken over maintaining the email package. I'm working my way through the old bug queue, and I can only deal with them in the context in which I find them. -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue1681333 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue11584] email/header.py: missing str()ification, and bogus encode()s
R. David Murray rdmur...@bitdance.com added the comment: I don't see a test case here, did you forget to attatch something? Also, in this: elf._msg[n] = email.header.make_header(email.header.decode_header(b)) unless 'b' is an ASCII-only string, it isn't going to work. -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue11584 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue11584] email/header.py: missing str()ification, and bogus encode()s
Changes by R. David Murray rdmur...@bitdance.com: -- assignee: - r.david.murray stage: - test needed type: - behavior versions: +Python 3.2 ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue11584 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue11383] compilation seg faults on insanely large expressions
SilentGhost ghost@gmail.com added the comment: 100k is, apparently, not enough on my system (linux2). test_crashers now fails. Are any system-specific details needed? -- nosy: +SilentGhost ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue11383 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue11585] Documentation 1.8 shows Python 2 example
New submission from Clive Darke clive.da...@qa.com: Python 3.2 version attached -- assignee: docs@python components: Documentation files: parrot.c messages: 131246 nosy: cdarke, docs@python priority: normal severity: normal status: open title: Documentation 1.8 shows Python 2 example versions: Python 3.1, Python 3.2 Added file: http://bugs.python.org/file21267/parrot.c ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue11585 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue11585] Documentation 1.8 shows Python 2 example
Clive Darke clive.da...@qa.com added the comment: 1.8. Keyword Parameters for Extension Functions Here is an example module which uses keywords, based on an example by Geoff Philbrick (philbr...@hks.com): The example which follows will not compile on Python 3. -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue11585 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue11383] compilation seg faults on insanely large expressions
SilentGhost ghost@gmail.com added the comment: 10**6 on the other hand seem to do the job -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue11383 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue11582] Boilerplate code replaced in Python/ceval.c
Amaury Forgeot d'Arc amaur...@gmail.com added the comment: Hmm, this kind of macros make it difficult to step line by line in a debugger. From this point of view, an inlined function would be better, I'm not sure if this can have a performance impact though. -- nosy: +amaury.forgeotdarc ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue11582 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue10535] Enable warnings by default in unittest
Brian Curtin br...@python.org added the comment: I'm not seeing those warnings anymore, so I think the patch can be ignored. -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue10535 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue11582] Boilerplate code replaced in Python/ceval.c
Changes by Antoine Pitrou pit...@free.fr: -- nosy: +pitrou ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue11582 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue11586] Python/pythonrun.c: get_codec_name() typo
New submission from Ray.Allen ysj@gmail.com: I guess there is a typo in the source of this function: Python/pythonrun.c: get_codec_name() diff -r 48970d754841 Python/pythonrun.c --- a/Python/pythonrun.cThu Mar 17 17:06:27 2011 +0800 +++ b/Python/pythonrun.cThu Mar 17 22:11:15 2011 +0800 @@ -147,7 +147,7 @@ goto error; name_utf8 = _PyUnicode_AsString(name); -if (name == NULL) +if (name_utf8 == NULL) goto error; name_str = strdup(name_utf8); Py_DECREF(name); -- components: Interpreter Core messages: 131252 nosy: ysj.ray priority: normal severity: normal status: open title: Python/pythonrun.c: get_codec_name() typo versions: Python 3.3 ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue11586 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue11587] METH_KEYWORDS alone gives METH_OLDARGS is no longer supported!
New submission from Clive Darke clive.da...@qa.com: In the PyMethodDef struct, METH_VARARGS | METH_KEYWORDS works fine. METH_KEYWORDS on its own gives: SystemError: Bad call flags in PyCFunction_Call. METH_OLDARGS is no longer supported! METH_KEYWORDS on its own tested OK on 2.6 and 2.7, fails as described on 3.1.2 and 3.2. -- components: Extension Modules messages: 131253 nosy: cdarke priority: normal severity: normal status: open title: METH_KEYWORDS alone gives METH_OLDARGS is no longer supported! type: compile error versions: Python 3.1, Python 3.2 ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue11587 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue11586] Python/pythonrun.c: get_codec_name() typo
Changes by Antoine Pitrou pit...@free.fr: -- assignee: - haypo nosy: +haypo ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue11586 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue11587] METH_KEYWORDS alone gives METH_OLDARGS is no longer supported!
Ray.Allen ysj@gmail.com added the comment: Looks like just the problem of error msg. -- nosy: +ysj.ray ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue11587 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue11584] email.decode_header fails if msg.__getitem__ returns Header object
R. David Murray rdmur...@bitdance.com added the comment: If the message contains 8bit bytes in a header, then getitem is going to return a Header object. decode_header does not operate on Header objects, as you have observed. Thinking about it some more, having decode_header operate on a Header and return its chunks is a decent binary interface for Header. This is right on the borderline between a feature and a bug fix, but given that getitem returning Header after a parse is a new feature in 3.2, I think I'm going to treat it as a bug that decode_header doesn't handle that case. -- stage: test needed - needs patch title: email/header.py: missing str()ification, and bogus encode()s - email.decode_header fails if msg.__getitem__ returns Header object ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue11584 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue11505] string.py increased test coverage
Nick Coghlan ncogh...@gmail.com added the comment: Reopening to double check with Jerome's patch. -- resolution: fixed - stage: committed/rejected - commit review status: closed - open ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue11505 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue11583] os.path.isdir() is slow on windows
Martin v. Löwis mar...@v.loewis.de added the comment: Ok. It's probably not the most optimal thing we can do. It opens the directory with CreateFileW (specifying OPEN_EXISTING and BACKUP_SEMANTICS), then GetFileInformationByHandle. If we only want to find out whether the file is a directory, we could just to FindFirstFile, which wouldn't need to go to the MFT record. I would be surprised if this makes a difference in practice, though. -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue11583 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue11587] METH_KEYWORDS alone gives METH_OLDARGS is no longer supported!
Clive Darke clive.da...@qa.com added the comment: Same error on 3.2 with Windows MSC v.1500 and Linux gcc version 4.1.2 -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue11587 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue11577] testcase for exception binhex.Error
Nick Coghlan ncogh...@gmail.com added the comment: This is fixed on default as well, I just stuffed the merge so the history looks odd and the integration script didn't pick it up. You can see the additional changes I made in the linked changeset: - try/except with a flag to clean up implicitly created file objects when binhex.__init__ fails - change the getfileinfo code to use a with statement so it is also more exception tolerant -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue11577 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue11583] os.path.isdir() is slow on windows
Brian Curtin br...@python.org added the comment: I made a bunch of the stat changes in 3.2 so I'll assign this to myself and take a look. -- assignee: - brian.curtin stage: - needs patch ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue11583 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue4492] httplib code thinks it closes connection, but does not
Changes by Ray.Allen ysj@gmail.com: -- nosy: +ysj.ray ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue4492 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue1681333] email.header unicode fix
Barry A. Warsaw ba...@python.org added the comment: Sadly, I agree with RDM. There are too many workarounds in the field for this bug so it can really only be fixed in email6. -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue1681333 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue11588] Add necessarily inclusive groups to argparse
New submission from John Didion johndid...@gmail.com: Just as some options are mutually exclusive, there are others that are necessarily inclusive, i.e. all or nothing. I propose the addition of ArgumentParser.add_necessarily_inclusive_group(required=True). This also means that argparse will need to support nested groups. For example, if I want to set up options such that the user has to provide an output file OR (an output directory AND (an output file pattern OR an output file extension)): output_group = parser.add_mutually_exclusive_group(required=True) output_group.add_argument(-o, --outfile) outdir_group = output_group.add_necessarily_inclusive_group() outdir_group.add_argument(-O, --outdir) outfile_group = outdir_group.add_mutually_exclusive_group(required=True) outfile_group.add_argument(-p, --outpattern) outfile_group.add_argument(-s, --outsuffix) The usage should then look like: (-o FILE | (-O DIR (-p PATTERN | -s SUFFIX)) -- messages: 131262 nosy: John.Didion priority: normal severity: normal status: open title: Add necessarily inclusive groups to argparse type: feature request versions: Python 2.7 ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue11588 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue11589] Unit test extensions for email module
New submission from Michael Henry pyt...@drmikehenry.com: The attached patch includes additional unit tests for the email module, and splits pre-existing test_header_encode() and test_decode() functions into individual test functions. -- components: Library (Lib) files: test_email_additional_tests.patch keywords: patch messages: 131263 nosy: michael.henry, r.david.murray priority: normal severity: normal status: open title: Unit test extensions for email module Added file: http://bugs.python.org/file21269/test_email_additional_tests.patch ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue11589 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue11588] Add necessarily inclusive groups to argparse
Changes by SilentGhost ghost@gmail.com: -- nosy: +bethard ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue11588 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue4114] struct returns incorrect 4 byte float
Robert Withrow bigbaaad...@gmail.com added the comment: Martin: in C I have the luxury of using 32 bit floats; not an option in Python. Simple code doing the moral equivalent of NTOHL(HTONL()) works in this case for C but wouldn't help for Python. Mark: I understand about the precision truncation issue and how Python does floating point arithmetic. This C code clearly demonstrates what is going on: #include stdio.h int main(int argc, char *argv[]) { double d1 = 6.21; float f = 6.21; double d2 = f; printf(double: %.15f\n, d1); printf(float: %.15f\n, f); printf(double converted from float: %15.15f\n, d2); } The point here is about the contract of struct, NOT how Python does floating point arithmetic. The contract is: what pack packs, unpack will unpack resulting in the original value. At least, that is what the documentation leads you to believe. For the 'f' format character, this contract is broken because of a basic implementation detail of Python and there is nothing in the documentation for struct that *directly* lets you know this will happen. After all, the mentions in the documentation about 32 bit versus 64 bit talk about C not Python! Even worse, there is no straightforward way (that I'm aware of) to write portable tests for code using the 'f' format character. In my case I'm writing a tool that creates message codecs in multiple languages and the most basic unit test goes something like this: m1 = example.message() m1.f1 = 6.21 b = m.encode() # uses struct pack m2 = example.message(b) # uses struct unpack if m1 != m2: # rich comparison print('fail') This test will fail when you use the 'f' format code. I suggest two things could be done to improve the situation: 1) Add a note to the documentation for struct that tells you that unpack(pack) using the 'f' format code will not generally give you the results you probably expect because insert pointer to discussion of pythons use of C double versus C float here. 2) Create a way in Python to write portable code related to 32 bit floats. For example, if I had a way in Python to cause the precision truncation programmatically: m1 = example.message() m1.f1 = 6.21.as_32_bit_float() # Does the precision truncation upfront b = m.encode() # uses struct pack m2 = example.message(b) # uses struct unpack if m1 != m2: # rich comparison print('fail') I'd expect this test to pass. Hope this long-winded note helps. -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue4114 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue11590] email quoprimime.py patch for header_encode of empty string, decode with different eol
New submission from Michael Henry pyt...@drmikehenry.com: The attached patch adds unit tests and some minor fixes for the email module's quoprimime.py file. The header_encode() function did not properly return an empty string when given an empty string. The decode() function did not properly detect the input string's EOL character. This patch depends on application of the patch in issue #11589. -- components: Library (Lib) files: quoprimime_patch_header_encode_decode.patch keywords: patch messages: 131265 nosy: michael.henry, r.david.murray priority: normal severity: normal status: open title: email quoprimime.py patch for header_encode of empty string, decode with different eol Added file: http://bugs.python.org/file21270/quoprimime_patch_header_encode_decode.patch ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue11590 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue4114] struct returns incorrect 4 byte float
Martin v. Löwis mar...@v.loewis.de added the comment: Martin: in C I have the luxury of using 32 bit floats; not an option in Python. Simple code doing the moral equivalent of NTOHL(HTONL()) works in this case for C but wouldn't help for Python. If you agree that Python actually behaves correct, I fail to understand what it is that you disagree with in msg131195 If all you want is a documentation change, can you please propose specific wording? Even worse, there is no straightforward way (that I'm aware of) to write portable tests for code using the 'f' format character. If you use numbers that are exactly representable as floats, the test should be portable to all platforms that use 32-bit IEEE-754 floats. If you then also use numbers without a fractional part, it should even port to non-IEEE platforms (as long as you don't test for the intermediate bytes). [...] This test will fail when you use the 'f' format code. So use 6.25 instead. -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue4114 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue10979] setUpClass exception causes explosion with -b
Roundup Robot devnull@devnull added the comment: New changeset d6abdd78d2af by Michael Foord in branch '2.7': Issue #10979. unittest stdout buffering now works for class and module fixtures. http://hg.python.org/cpython/rev/d6abdd78d2af -- nosy: +python-dev ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue10979 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue11581] buildbot error when pushing to 2.5 branch?
Skip Montanaro s...@pobox.com added the comment: Should you be pushing anything to 2.5? -- nosy: +skip.montanaro ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue11581 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue11579] python 2.5 does not build from hg - looks for subversion keywords
Skip Montanaro s...@pobox.com added the comment: See Issue 11439. -- nosy: +skip.montanaro ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue11579 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue11470] Flag inappropriate uses of callable class attributes
Thomas Wouters tho...@python.org added the comment: New version of the patch; instead of triggering at attribute *access*, this just checks when creating types and in type_setattro. It also makes the warning a newly added CompatibilityWarning. Also, instead of warning for all non-descriptors, it now only warns for PyCFunctionObjects that do not have a __self__ set, or of which __self__ is a module. (The reason for the latter being the new-ish behaviour of functions defined in modules in C getting passed something as __self__, defaulting to the module.) I've removed a few staticmethod calls from cases that do not trigger the new warning. This patch still lacks tests and doc updates, but I'm uploading right now because the sprints apparently lose internet soonish. -- Added file: http://bugs.python.org/file21271/nonmethod-warn.diff ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue11470 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue11470] Flag inappropriate uses of callable class attributes
Changes by Thomas Wouters tho...@python.org: Removed file: http://bugs.python.org/file21088/nonmethod-warn-nongit.diff ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue11470 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue10979] setUpClass exception causes explosion with -b
Roundup Robot devnull@devnull added the comment: New changeset 0f7036ea0930 by Michael Foord in branch '3.2': Issue #10979. unittest stdout buffering now works with class and module setup and teardown. http://hg.python.org/cpython/rev/0f7036ea0930 -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue10979 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue11506] b'' += gives SystemError instead of SyntaxError
Changes by Andreas Stührk andy-pyt...@hammerhartes.de: Removed file: http://bugs.python.org/file21140/issue_11506.patch ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue11506 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue11506] b'' += gives SystemError instead of SyntaxError
Andreas Stührk andy-pyt...@hammerhartes.de added the comment: Added a test. Perhaps that should be done for other literals as well? -- Added file: http://bugs.python.org/file21272/issue_11506.patch ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue11506 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue4114] struct returns incorrect 4 byte float
Robert Withrow bigbaaad...@gmail.com added the comment: If you agree that Python actually behaves correct, I fail to understand what it is that you disagree with in msg131195 I don't agree that Python is behaving correctly as far as the documented contract for struct is concerned. I disagree with the statement in the preceding msg74708 which says: people should read general CS introductory material to learn how floating point numbers work. Aside from being patronizing it doesn't solve the problem in any meaningful way. If you use numbers that are exactly representable as floats, the test should be portable to all platforms that use 32-bit IEEE-754 floats. A reasonable suggestion, but it is a constrained definition of portable. Since most (or nearly all?) modern platforms use '754 it is probably not a bad constraint, given that struct explicitly uses '754. If you then also use numbers without a fractional part, it should even port to non-IEEE platforms I confess, the CS introductory material I read 30 years ago (predating '754) don't give me enough information to know if this is correct. Anyway: If all you want is a documentation change, can you please propose specific wording? It isn't exactly all I want, but it is a good start. I note that msg74705 suggests adding documentation to struct about the 'f' format code. First of all, as far as I know, struct is the only place where this issue of 32 bit versus 64 bit floating point numbers shows up in Python because the rest of Python uses only 64 bit numbers. (Is there anywhere else in Python where a 32 bit float is converted to a 64 bit float?) So the documentation probably belongs in struct. I would add to note 4 of 7.3.2.2 (in the 2.7.1 documentation) something like: Note that 32 bit representations do not generally convert exactly to 64 bit representations (which Python uses internally) so that the results of unpack(fmt,pack(fmt,number)) may not equal number when using the 'f' format character. It would be friendly to add an example at the bottom demonstrating the issue and incorporating your comments about fractions and non-fractional values. x = unpack('!f', pack('!f', 6.24))[0] x == 6.24 False x = unpack('!f', pack('!f', 6.25))[0] x == 6.25 True -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue4114 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue10979] setUpClass exception causes explosion with -b
Roundup Robot devnull@devnull added the comment: New changeset 9c09ba72136e by Michael Foord in branch 'default': Closes issue 10979. unittest buffering now works with class and module setup and teardown http://hg.python.org/cpython/rev/9c09ba72136e -- resolution: - fixed stage: - committed/rejected status: open - closed ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue10979 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue11583] os.path.isdir() is slow on windows
Changes by Daniel Stutzbach stutzb...@google.com: -- nosy: +stutzbach ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue11583 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue10812] Add some posix functions
Roundup Robot devnull@devnull added the comment: New changeset 525320df8afb by Ross Lagerwall in branch 'default': Issue #10812: Add some extra posix functions to the os module. http://hg.python.org/cpython/rev/525320df8afb -- nosy: +python-dev ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue10812 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue4114] struct returns incorrect 4 byte float
Raymond Hettinger raymond.hettin...@gmail.com added the comment: The suggested examples are misleading because they use 6.24 which is not exactly representable in binary floating point. Representation issues are orthogonal to the OP's issue which is really just a simple rounding example: x = float.fromhex('0x0.123456001') unpack('!f', pack('!f', x))[0].hex() '0x1.23456p-4' Also, if something like the suggested note is adopted, it needs to be worded in a way that doesn't imply that the struct implementation is broken or misdesigned. A better note would focus on the basic (and obvious) fact that downgrading from double precision to single precision entails a loss of precision. -- nosy: +rhettinger ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue4114 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue10812] Add some posix functions
Changes by Ross Lagerwall rosslagerw...@gmail.com: -- assignee: - rosslagerwall resolution: - accepted stage: patch review - committed/rejected status: open - closed ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue10812 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue11563] test_urllibnet is triggering a ResourceWarning
Jeff McNeil j...@jmcneil.net added the comment: So, it turned out to be more complicated than that. The HTTPConnection object returns an HTTPResponse, but never closes the underlying socket after calling makesock. Since persistent connections aren't supported, nothing actually closes the socket itself, it's just set to None. Explicitly calling a close turns out not to be correct either. I went down the same path as AbstractHTTPHandler and added a Connection: close header. That ensures that the remote host will close the underlying connection (more importantly, setting the HTTP Response object's will_close to True). That ensures HTTPConnection performs in a fire and forget mode, causing everything to close out as it should. I contemplated changing urlretrieve to use build_opener as urlopen does, but I figure that would have been done by now if it was a trivial operation. I'd be happy to take a whack at it if it's just a matter of getting around to it. -- keywords: +patch Added file: http://bugs.python.org/file21273/11562.patch ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue11563 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue4114] struct returns incorrect 4 byte float
Robert Withrow bigbaaad...@gmail.com added the comment: it needs to be worded in a way that doesn't imply that the struct implementation is broken or misdesigned. Agree. A better note would focus on the basic (and obvious) fact that downgrading from double precision to single precision entails a loss of precision. Sort of where I was going, but I'm sure my text could be vastly improved. The suggested examples are misleading because they use 6.24 which is not exactly representable in binary floating point. I'd quibble with this for two reasons: 1) to be precise, numbers which are not exactly representable in binary floating point would nonetheless pass the unpack(pack) test if you use the 'd' format character. The key issue is, as you said, loss of precision. 2) I don't understand why the 6.24 example is misleading when it accurately demonstrates the issue. One comment about portability I forgot to mention earlier: I don't know how wed Python is to '754 or even binary floating point representations. My personal belief is that it should be possible to write a test so that the unpack(fmt, pack(fmt, precision_truncate(number))) == precision_truncate(number) test works for any legal number on any platform. I don't like the idea that one has to pick specific numbers based on knowledge of the platform's floating point format. I acknowledge that this may not bother others as much as it bothers me though. I'm a portability nut. -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue4114 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue5421] Irritating error message by socket's sendto method
Vetoshkin Nikita nikita.vetosh...@gmail.com added the comment: ping? -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue5421 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue1195] Problems on Linux with Ctrl-D and Ctrl-C during raw_input
Vetoshkin Nikita nikita.vetosh...@gmail.com added the comment: up! -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue1195 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue11591] python -S should be robust against e.g. from site import addsitedir
New submission from Carl Meyer c...@dirtcircle.com: If python is run with the -S flag, that declares the intent of the user to not have site-specific additions to sys.path. However, some code in that process may have a legitimate need for a function defined in site.py - for instance, addsitedir. But the act of importing site.py, as a side effect, adds the standard site-specific directories to sys.path. python -S would be more useful and reliable if it prevented importing site from automatically making the sys.path additions. There is no loss of flexibility here, as user code could still explicitly call site.main() to achieve all of the current side-effects of import site. The fix is a one-liner, and is in the linked hg repository. -- components: Library (Lib) hgrepos: 4 messages: 131281 nosy: carljm priority: normal severity: normal status: open title: python -S should be robust against e.g. from site import addsitedir type: behavior ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue11591 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue11591] python -S should be robust against e.g. from site import addsitedir
Changes by Carl Meyer c...@dirtcircle.com: -- keywords: +patch Added file: http://bugs.python.org/file21274/87df1d37c88e.diff ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue11591 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue10812] Add some posix functions
Roundup Robot devnull@devnull added the comment: New changeset 8945e087a5a6 by Ross Lagerwall in branch 'default': Issue #10812: Revert os.lseek change. http://hg.python.org/cpython/rev/8945e087a5a6 -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue10812 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue11582] Boilerplate code replaced in Python/ceval.c
knickerkicker knicker.kic...@gmail.com added the comment: Creating a inline function would require passing the stackpointer variable so that the TOP() and POP() macros continue working, and creating variables for u, v and x. I am not sure if that will not have a performance impact - ideally it shouldn't, but can we trust the compilers to see what we're upto? Also, the DISPATCH() macro will still need to be outside the inline function. -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue11582 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue5421] Irritating error message by socket's sendto method
Matt Joiner anacro...@gmail.com added the comment: This bug is very misleading in Py3, as the TypeError makes one think that a string is being passed rather than bytes (how else do you get a 2 argument function call wrong?). Very difficult to determine that this is not in fact the bug in a dynamically typed language :P -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue5421 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue11582] Boilerplate code replaced in Python/ceval.c
Raymond Hettinger raymond.hettin...@gmail.com added the comment: -1 I think this will make the code harder to understand and maintain. -- nosy: +rhettinger ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue11582 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue11582] Boilerplate code replaced in Python/ceval.c
Changes by Raymond Hettinger raymond.hettin...@gmail.com: -- priority: normal - low versions: -Python 3.1, Python 3.2, Python 3.4 ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue11582 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue11591] python -S should be robust against e.g. from site import addsitedir
Éric Araujo mer...@netwok.org added the comment: Thanks. Would you mind adding tests in test_site? -- nosy: +eric.araujo versions: +Python 3.3 ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue11591 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue11592] Compilation warnings in os module
New submission from Antoine Pitrou pit...@free.fr: Under Linux: ./Modules/posixmodule.c: In function ‘posix_readv’: ./Modules/posixmodule.c:6239: attention : implicit declaration of function ‘readv’ ./Modules/posixmodule.c: In function ‘posix_writev’: ./Modules/posixmodule.c:6583: attention : implicit declaration of function ‘writev’ Yet the presence of sys/uio.h seems correctly detected: $ grep UIO pyconfig.h #define HAVE_SYS_UIO_H 1 -- assignee: rosslagerwall messages: 131287 nosy: pitrou, rosslagerwall priority: normal severity: normal status: open title: Compilation warnings in os module type: behavior versions: Python 3.3 ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue11592 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue5421] Irritating error message by socket's sendto method
Roundup Robot devnull@devnull added the comment: New changeset c61b72b0650d by Antoine Pitrou in branch '3.1': Issue #5421: Fix misleading error message when one of socket.sendto()'s http://hg.python.org/cpython/rev/c61b72b0650d New changeset 2af7a6d765fd by Antoine Pitrou in branch '3.2': Issue #5421: merge fix http://hg.python.org/cpython/rev/2af7a6d765fd New changeset 90cdc371a3b8 by Antoine Pitrou in branch 'default': Issue #5421: merge fix http://hg.python.org/cpython/rev/90cdc371a3b8 -- nosy: +python-dev ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue5421 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue5421] Irritating error message by socket's sendto method
Antoine Pitrou pit...@free.fr added the comment: Thank you for the patch! This is now fixed in 3.x. -- nosy: +pitrou resolution: - fixed stage: needs patch - committed/rejected status: open - closed versions: +Python 3.2, Python 3.3 ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue5421 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue11574] Unicode Fallback Encoding on Python 3.3
STINNER Victor victor.stin...@haypocalc.com added the comment: In my experience (PYTHONFSENCODING, sys.setfilesystemencoding()): Python should just use the same encoding than the locale encoding because *all* other programs on the system use the locale encoding. If none of LANG, LC_ALL or LC_CTYPE env var is set: Python does use ASCII just because nl_langinfo() answers ASCII. Said differently: get_codeset() doesn't fail if there is no environment variable. If get_codeset() does fail: Python stops immediatly with a fatal error, it doesn't fallback to ASCII or something like that. Python 3.2 used ASCII at startup until the locale encoding codec was loaded (to avoid a bootstrap issue). But I fixed the bootstrap issue in Python 3.2: Python does now *always* use the locale encoding, even at startup. Before the codec is complelty loaded: Python uses _Py_char2wchar() to decode filenames (and other data). For more information, see also a previous attempt: issue #8725. -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue11574 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue11573] Improve Unicode Documentation with Known Caveats
STINNER Victor victor.stin...@haypocalc.com added the comment: Can you provide a patch? -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue11573 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue11320] Usage of API method Py_SetPath causes errors in Py_Initialize() (Posix ony))
Antoine Pitrou pit...@free.fr added the comment: Sridhar: I'm sorry, but at this point you should investigate a bit more into the actual causes of the problem. I'm not going to dig in virtualenv myself. Also, since there's already #10743 for the virtualenv issue, perhaps further virtualenv-related comments should be posted there. (Palm, I take it your issue doesn't have anything to do with virtualenv?) -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue11320 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue11320] Usage of API method Py_SetPath causes errors in Py_Initialize() (Posix ony))
Antoine Pitrou pit...@free.fr added the comment: Ok, Palm's example even segfaults here: Program received signal SIGSEGV, Segmentation fault. 0x772452bc in free () from /lib64/libc.so.6 (gdb) bt #0 0x772452bc in free () from /lib64/libc.so.6 #1 0x0042a591 in Py_SetPath ( path=0x88c330 L/home/antoine/cpython/default/usr/lib/python33.zip:/home/antoine/cpython/default/usr/lib/python3.3/:/home/antoine/cpython/default/usr/lib/python3.3/plat-linux2:/home/antoine/cpython/default/usr/lib/py...) at ./Modules/getpath.c:729 #2 0x00416600 in main () The problem is calling free() on a pointer to statically allocated memory. -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue11320 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue11591] python -S should be robust against e.g. from site import addsitedir
Carl Meyer c...@dirtcircle.com added the comment: Adding a test is easier said than done. The behavior change here depends on python being run with -S. Currently test_site skips itself if the test suite is run with -S, and if I remove that skip it crashes under -S. Options as I see it: 1. Declare this one-liner correct by inspection. It doesn't break any existing tests. 2. Add a new test file (test_no_site.py?) that only runs with -S and tests that importing something from site doesn't trigger sys.path additions. This seems like the most reasonable test, but I'm not sure how useful it is, since I doubt most people ever try running the test suite with -S. 3. Make the fix more complicated such that it uses an intermediary variable which can be mocked (unlike sys.flags.no_site, which is read-only), and then add a test which mocks this variable, temporarily removes site from sys.modules, tries importing it again, and checks whether main() is called. This creates a complex test which is highly coupled to the implementation in site.py, but would be run under normal conditions (without -S). Which option do you prefer? -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue11591 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue10914] Python sub-interpreter test
Roundup Robot devnull@devnull added the comment: New changeset a791dd7d51f3 by Antoine Pitrou in branch '3.2': Issue #10914: fix bogus memory management in Modules/getpath.c, leading to a possible crash when calling Py_SetPath() http://hg.python.org/cpython/rev/a791dd7d51f3 -- nosy: +python-dev ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue10914 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue10914] Python sub-interpreter test
Antoine Pitrou pit...@free.fr added the comment: Ouch, sorry, I got my commit message wrong. -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue10914 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue11320] Usage of API method Py_SetPath causes errors in Py_Initialize() (Posix ony))
Antoine Pitrou pit...@free.fr added the comment: Crash fixed in a791dd7d51f3 (3.2) and b4104ffd5127 (3.3), but the original problem remains, or a variant of it. I now get: Init Fatal Python error: Py_Initialize: Unable to get the locale encoding LookupError: no codec search functions registered: can't find encoding Abandon -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue11320 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue11581] buildbot error when pushing to 2.5 branch?
Senthil Kumaran orsent...@gmail.com added the comment: On Thu, Mar 17, 2011 at 05:15:09PM +, Skip Montanaro wrote: Should you be pushing anything to 2.5? I think, there is a security release planned in 2011. Also, see issue11442 which was the specific case for pushing to 2.5. -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue11581 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue11579] python 2.5 does not build from hg - looks for subversion keywords
Senthil Kumaran orsent...@gmail.com added the comment: On Thu, Mar 17, 2011 at 05:16:43PM +, Skip Montanaro wrote: See Issue 11439. Yes, that is relevant and applies probably to code in default and other branches. Just in case, this corner case in 2.5 does not overlooked (because it does not happen in other branches), I think it is a good idea to keep this open and fix it with the patch attached in this issue. -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue11579 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue11320] Usage of API method Py_SetPath causes errors in Py_Initialize() (Posix ony))
Changes by Antoine Pitrou pit...@free.fr: -- nosy: +haypo ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue11320 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue11572] bring Lib/copy.py to 100% coverage
Éric Araujo mer...@netwok.org added the comment: Some code is removed by your patch, for example a check that prevented an error for builds that don’t include complex. If this type of builds still exist, the code should be compatible. Conversely, the code mentions unicode in some places, but it’s gone now. -- nosy: +eric.araujo ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue11572 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue11320] Usage of API method Py_SetPath causes errors in Py_Initialize() (Posix ony))
Antoine Pitrou pit...@free.fr added the comment: Ok, the issue here is that you can't call Py_SetPath() on the point returned by Py_GetPath(), since the memory refered to that pointer is free()d at the beginning of Py_SetPath(). The following works, though: main(int argc, char **argv) { wchar_t *path, *newpath; path = Py_GetPath(); newpath = malloc((wcslen(path) + 1) * sizeof(wchar_t)); wcscpy(newpath, path); Py_SetPath(newpath); free(newpath); printf(Init\n); Py_Initialize(); printf(-- END\n); } Perhaps we could modify Py_SetPath() so that it copies the new path first before deallocating the old one, but I'm not sure I see the point of calling Py_SetPath() with the pointer returned by Py_GetPath(). -- versions: +Python 3.3 ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue11320 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue11320] Can't call Py_SetPath() on pointer returned by Py_GetPath()
Changes by Antoine Pitrou pit...@free.fr: -- priority: high - normal title: Usage of API method Py_SetPath causes errors in Py_Initialize() (Posix ony)) - Can't call Py_SetPath() on pointer returned by Py_GetPath() type: crash - behavior ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue11320 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue10914] Python sub-interpreter test
Éric Araujo mer...@netwok.org added the comment: distutils sure knows how to build .o or .so files, but I don’t know about standalone executables (because I don’t know how the .o end up making an executable). If you want to try to do it, I would advise you not to use the config command but rather a compiler object directly. distutils.ccompiler.new_compiler() should give you an instance of a subclass of distutils.ccompiler.CCompiler suitable for your system, and then you can use help or the source to find what methods to call. -- nosy: +eric.araujo ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue10914 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue11573] Improve Unicode Documentation with Known Caveats
Changes by Éric Araujo mer...@netwok.org: -- assignee: - docs@python components: +Documentation nosy: +docs@python versions: -Python 3.4 ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue11573 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com