[issue23063] `python setup.py check --restructuredtext --strict --metadata` fails with: `warning: check: Could not finish the parsing.` if the RST document uses code or code-block directives.

2014-12-16 Thread Marc Abramowitz
Marc Abramowitz added the comment: Testing a few common cases: $ python setup.py check --restructuredtext --strict --metadata running check error: The docutils package is needed. $ python setup.py check --restructuredtext --strict --metadata running check warning: check: Cannot analyze code. Py

[issue23063] `python setup.py check --restructuredtext --strict --metadata` fails with: `warning: check: Could not finish the parsing.` if the RST document uses code or code-block directives.

2014-12-16 Thread Marc Abramowitz
Marc Abramowitz added the comment: Note that this patch does 2 things: 1. Improves the error message 2. Prevents check from failing when there are code-blocks If I only did #1 and not #2, then output looks like this: $ python setup.py check --restructuredtext --strict --metadata && echo "RST w

[issue22733] MSVC ffi_prep_args doesn't handle 64-bit arguments properly

2014-12-16 Thread Tim Golden
Tim Golden added the comment: Likewise. -- ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.

[issue14134] xmlrpc.client.ServerProxy needs timeout parameter

2014-12-16 Thread Demian Brecht
Demian Brecht added the comment: > in GNU/Linux "system timeout has been reached" -- means that system timeout > will *never* reached. That's quite likely because the system limits may be very large. For example, on my OSX box: --- ~ » sysctl net.inet.tcp.keepinit net.inet.tcp.keepin

[issue20577] IDLE: Remove FormatParagraph's width setting from config dialog

2014-12-16 Thread Roundup Robot
Roundup Robot added the comment: New changeset 51de0da524b4 by Terry Jan Reedy in branch '2.7': Issue #20577: move configuration of FormatParagraph extension to new extension https://hg.python.org/cpython/rev/51de0da524b4 New changeset 3ffa8438d274 by Terry Jan Reedy in branch '3.4': Issue #2057

[issue14134] xmlrpc.client.ServerProxy needs timeout parameter

2014-12-16 Thread Andrej A Antonov
Andrej A Antonov added the comment: I just will write next code-fragment: import socket s = socket.socket(socket.AF_INET, socket.SOCK_STREAM, socket.IPPROTO_TCP) s.connect(('python.org', 80)) print( 'is my operation system using (by default) "tcpkeepalive"-algorithm

[issue20577] IDLE: Remove FormatParagraph's width setting from config dialog

2014-12-16 Thread Terry J. Reedy
Changes by Terry J. Reedy : -- assignee: -> terry.reedy resolution: -> fixed stage: commit review -> resolved status: open -> closed ___ Python tracker ___

[issue14134] xmlrpc.client.ServerProxy needs timeout parameter

2014-12-16 Thread Andrej A Antonov
Andrej A Antonov added the comment: >> in GNU/Linux "system timeout has been reached" -- means that system timeout >> will *never* reached. > That's quite likely because the system limits may be very large. I tested system-timeout GNU/Linux (on various computers). I waited more then 5 days.

[issue23060] Assert fails in multiprocessing.heap.Arena.__setstate__ on Windows

2014-12-16 Thread Tim Golden
Tim Golden added the comment: I agree that this is a fragile assertion; it's too far removed from the CreateFileMapping call which can generate it and almost impossible to work around (in calling code) if it should fail in the way we're seeing in the buildbot. I think we're better off relying on

[issue22980] C extension naming doesn't take bitness into account

2014-12-16 Thread Marc-Andre Lemburg
Marc-Andre Lemburg added the comment: On 16.12.2014 05:54, Steve Dower wrote: > Nobody seemed too bothered by it, so I committed a slightly simpler change > that only includes the most specific tag (that is, ".cp35-win32.pyd" or > ".pyd"). We can always add another tag easily enough if it seems

[issue23064] pep8 asyncore.py

2014-12-16 Thread liu chang
New submission from liu chang: pep8 Lib/asycore.py. -- components: Library (Lib) files: pep8-asyncore.patch hgrepos: 287 keywords: patch messages: 232730 nosy: 畅.刘 priority: normal severity: normal status: open title: pep8 asyncore.py type: enhancement versions: Python 3.4 Added file: ht

[issue14134] xmlrpc.client.ServerProxy needs timeout parameter

2014-12-16 Thread Andrej A Antonov
Andrej A Antonov added the comment: @demian.brecht , for high probably to catch *infinite_freeze* (at GNU/Linux) -- if we may will run requests of "xmlrpc.client.ServerProxy" -- parallely: (when running next code -- need to make some network-disconnections on "network-router-computer")

[issue21619] Cleaning up a subprocess with a broken pipe

2014-12-16 Thread Martin Panter
Martin Panter added the comment: Here is a patch to fix this by calling wait() even if stdin.close() fails, including a test case. With my patch, the subprocess context manager __exit__() will still raise a BrokenPipeError, but no zombie will be left. -- keywords: +patch Added file: ht

[issue23065] Pyhton27.dll at SysWOW64 not updated when updating Python 2.7.X

2014-12-16 Thread GamesGamble
New submission from GamesGamble: Hello, the Python27.dll at >C:\Windows\SysWOW64< not get updated when updating Python 2.7.X at Windows 7 SP1 (Reported weak spot from Kaspersky Pure 3.0 weak spot search). When I´am manually deinstalling Python und install Python after deinstalling It got the u

[issue23063] `python setup.py check --restructuredtext --strict --metadata` fails with: `warning: check: Could not finish the parsing.` if the RST document uses code or code-block directives.

2014-12-16 Thread Berker Peksag
Changes by Berker Peksag : -- keywords: +patch Added file: http://bugs.python.org/file37464/cfabe07bc98f.diff ___ Python tracker ___ _

[issue23063] `python setup.py check --restructuredtext --strict --metadata` fails with: `warning: check: Could not finish the parsing.` if the RST document uses code or code-block directives.

2014-12-16 Thread Berker Peksag
Changes by Berker Peksag : -- stage: -> patch review versions: -Python 3.2, Python 3.3, Python 3.6 ___ Python tracker ___ ___ Python

[issue23063] `python setup.py check --restructuredtext --strict --metadata` fails with: `warning: check: Could not finish the parsing.` if the RST document uses code or code-block directives.

2014-12-16 Thread Berker Peksag
Berker Peksag added the comment: Could you add a test? See Lib/distutils/tests/test_check.py. -- nosy: +berker.peksag ___ Python tracker ___ _

[issue23056] tarfile raises an exception when reading an empty tar in streaming mode

2014-12-16 Thread liu chang
liu chang added the comment: 2232 def next(self): 2233 """Return the next member of the archive as a TarInfo object, when 2234TarFile is opened for reading. Return None if there is no more 2235available. 2236 """ 2237 self._check("ra") 2238

[issue23056] tarfile raises an exception when reading an empty tar in streaming mode

2014-12-16 Thread liu chang
liu chang added the comment: a simple fix -- keywords: +patch Added file: http://bugs.python.org/file37465/fix-tar-23056.patch ___ Python tracker ___

[issue23055] PyUnicode_FromFormatV crasher

2014-12-16 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: Here is updated patch for 2.7 (backported tests from 3.5), patches for 3.2 and 3.3. -- Added file: http://bugs.python.org/file37466/issue23055-2.7-2.patch Added file: http://bugs.python.org/file37467/issue23055-3.2.patch Added file: http://bugs.python

[issue19858] Make pickletools.optimize aware of the MEMOIZE opcode.

2014-12-16 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: Here is a patch which addresses Antoine's comments. Also added dis() output for binary example in comments. -- Added file: http://bugs.python.org/file37469/pickle_optimize_memoize_2.patch ___ Python tracker

[issue22783] Pickle: use NEWOBJ instead of NEWOBJ_EX if possible

2014-12-16 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: Updated patch addresses Antoine's comments. Also added few comments explaining binary data. -- Added file: http://bugs.python.org/file37470/pickle_newobj_2.patch ___ Python tracker

[issue22980] C extension naming doesn't take bitness into account

2014-12-16 Thread Steve Dower
Steve Dower added the comment: I justified leaving out the ABI tag in an earlier post as well as in an email to distutils-sig, where two of the PEPs you mention were developed, and nobody had any comment. Cache tags don't include platform information and are worthless here. distutils uses the

[issue23014] Don't have importlib.abc.Loader.create_module() be optional

2014-12-16 Thread Nick Coghlan
Nick Coghlan added the comment: I'm still a fan of "never" - it's a good escape hatch that means we never have to contort the new API to deal with some of the more esoteric use cases that involved completely overloading the import process in the loader :) -- __

[issue23064] pep8 asyncore.py

2014-12-16 Thread R. David Murray
R. David Murray added the comment: Thanks for the effort, but we do not apply PEP8-only patches. The small improvements in readability do not justify the costs of code churn and the chance of introducing bugs. (Also, FYI, PEP8 discourages using \ for line continuation.) -- nosy: +r.d

[issue19698] Implement _imp.exec_builtin and exec_dynamic

2014-12-16 Thread Nick Coghlan
Nick Coghlan added the comment: Turns out I had written up a recap of the PEP 451 C extension support status back in July, so I just resent that to import-sig. -- ___ Python tracker ___

[issue22945] Ctypes inconsistent between Linux and OS X

2014-12-16 Thread Daniel Standage
Daniel Standage added the comment: Sorry for my radio silence. Your example was very helpful, and restores the behavior I was looking for. Thanks! -- resolution: -> works for me status: open -> closed ___ Python tracker

[issue23014] Don't have importlib.abc.Loader.create_module() be optional

2014-12-16 Thread Brett Cannon
Brett Cannon added the comment: Yeah, we need to settle the whole load_module() thing at PyCon because I'm tired of it hanging over our heads since the code is entirely structured to yank it out and if it's going to stay I want to clean up _bootstrap.py to make the code flow easier to follow.

[issue23066] re.match hang

2014-12-16 Thread Jie Yin
New submission from Jie Yin: The following expression hang in 2.7.9 for the module re: re.match('^([a-zA-Z0-9]+|[\\s]+|[,.])+$', 'Feature Test Macro Requirements for glibc ()') -- components: Interpreter Core messages: 232746 nosy: writalnaie priority: normal severity: normal status: o

[issue23066] re.match hang

2014-12-16 Thread Benjamin Peterson
Changes by Benjamin Peterson : -- nosy: +serhiy.storchaka ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe: https

[issue23066] re.match hang

2014-12-16 Thread Guido van Rossum
Guido van Rossum added the comment: Please go to python-list to get help about writing re expressions for parsing. The example regexp does not technically hang, it is just exploring a very large set of alternatives, none of which match (because the trailing '()' doesn't match anything). -

[issue19858] Make pickletools.optimize aware of the MEMOIZE opcode.

2014-12-16 Thread Roundup Robot
Roundup Robot added the comment: New changeset c49b7acba06f by Serhiy Storchaka in branch '3.4': Issue #19858: pickletools.optimize() now aware of the MEMOIZE opcode, can https://hg.python.org/cpython/rev/c49b7acba06f New changeset e7dd739b4b4e by Serhiy Storchaka in branch 'default': Issue #19

[issue23060] Assert fails in multiprocessing.heap.Arena.__setstate__ on Windows

2014-12-16 Thread Antoine Pitrou
Antoine Pitrou added the comment: Or perhaps: buffer = mmap.mmap(-1, self.size, tagname=self.name) assert _winapi.GetLastError() == _winapi.ERROR_ALREADY_EXISTS self.buffer = buffer ? -- nosy: +pitrou ___ Python tracker

[issue15513] Correct __sizeof__ support for pickle

2014-12-16 Thread Roundup Robot
Roundup Robot added the comment: New changeset fed774c926f5 by Serhiy Storchaka in branch '3.4': Issue #15513: Added a __sizeof__ implementation for pickle classes. https://hg.python.org/cpython/rev/fed774c926f5 New changeset e11d99ed3d3f by Serhiy Storchaka in branch 'default': Issue #15513: Ad

[issue22783] Pickle: use NEWOBJ instead of NEWOBJ_EX if possible

2014-12-16 Thread Roundup Robot
Roundup Robot added the comment: New changeset 2ffaac4c8e53 by Serhiy Storchaka in branch 'default': Issue #22783: Pickling now uses the NEWOBJ opcode instead of the NEWOBJ_EX https://hg.python.org/cpython/rev/2ffaac4c8e53 -- nosy: +python-dev ___ Pyt

[issue19858] Make pickletools.optimize aware of the MEMOIZE opcode.

2014-12-16 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: Many thanks for all your reviews Antoine! -- assignee: -> serhiy.storchaka resolution: -> fixed stage: patch review -> resolved status: open -> closed ___ Python tracker __

[issue22783] Pickle: use NEWOBJ instead of NEWOBJ_EX if possible

2014-12-16 Thread Serhiy Storchaka
Changes by Serhiy Storchaka : -- assignee: -> serhiy.storchaka resolution: -> fixed stage: patch review -> resolved status: open -> closed ___ Python tracker ___ __

[issue22777] Test pickling with all protocols

2014-12-16 Thread Serhiy Storchaka
Changes by Serhiy Storchaka : -- status: open -> closed ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe: https:/

[issue23063] `python setup.py check --restructuredtext --strict --metadata` fails with: `warning: check: Could not finish the parsing.` if the RST document uses code or code-block directives.

2014-12-16 Thread Marc Abramowitz
Marc Abramowitz added the comment: OK, I added a test. See: * https://bitbucket.org/msabramo/cpython/commits/9b8f6812ff6981b5f195b6bf73cefb0fea46fba6 * https://bitbucket.org/msabramo/cpython/pull-request/1/fix-distutils-setuppy-check/diff If you want, I can also update the diff attached here

[issue23063] `python setup.py check --restructuredtext --strict --metadata` fails with: `warning: check: Could not finish the parsing.` if the RST document uses code or code-block directives.

2014-12-16 Thread Éric Araujo
Changes by Éric Araujo : -- hgrepos: +288 ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.o

[issue23063] `python setup.py check --restructuredtext --strict --metadata` fails with: `warning: check: Could not finish the parsing.` if the RST document uses code or code-block directives.

2014-12-16 Thread Éric Araujo
Changes by Éric Araujo : Added file: http://bugs.python.org/file37471/9b8f6812ff69.diff ___ Python tracker ___ ___ Python-bugs-list mailing li

[issue23063] `python setup.py check --restructuredtext --strict --metadata` fails with: `warning: check: Could not finish the parsing.` if the RST document uses code or code-block directives.

2014-12-16 Thread Éric Araujo
Changes by Éric Araujo : -- hgrepos: -286 ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.

[issue23063] `python setup.py check --restructuredtext --strict --metadata` fails with: `warning: check: Could not finish the parsing.` if the RST document uses code or code-block directives.

2014-12-16 Thread Marc Abramowitz
Changes by Marc Abramowitz : Added file: http://bugs.python.org/file37472/issue23063.patch ___ Python tracker ___ ___ Python-bugs-list mailing

[issue23063] `python setup.py check --restructuredtext --strict --metadata` fails with: `warning: check: Could not finish the parsing.` if the RST document uses code or code-block directives.

2014-12-16 Thread Éric Araujo
Éric Araujo added the comment: The Mercurial integration lets you update the patch with one click. Decentralized VCSes are nice :‑) Patch looks good to me. Thank you. -- ___ Python tracker _

[issue23060] Assert fails in multiprocessing.heap.Arena.__setstate__ on Windows

2014-12-16 Thread Steve Dower
Steve Dower added the comment: That was actually my first hack and it also works. The fundamental problem here is that GetLastError() is not actually meant to indicate *whether* an error has occurred, but when one has occurred it describes what it was. Indeed, in this case no error has occurre

[issue23063] `python setup.py check --restructuredtext --strict --metadata` fails with: `warning: check: Could not finish the parsing.` if the RST document uses code or code-block directives.

2014-12-16 Thread Marc Abramowitz
Marc Abramowitz added the comment: What's the next step? -- ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe: htt

[issue23067] Export readline forced_update_display

2014-12-16 Thread Chris Hand
New submission from Chris Hand: The current implementation of readline implements the redisplay function, but not the forced version. This patch maintains the current behavior as the default, but also allows a bool to be passed which, if True, calls rl_forced_update_display instead. -

[issue23054] ConnectionError: ('Connection aborted.', BadStatusLine(""''''"))

2014-12-16 Thread Joe Cabrera
Joe Cabrera added the comment: This is an error wrapping coming from requests. https://github.com/kennethreitz/requests/issues/2364 The Requests team has concluded they can do nothing about this error, I believe the next step up is the python httplib library. -- _

[issue22980] C extension naming doesn't take bitness into account

2014-12-16 Thread Marc-Andre Lemburg
Marc-Andre Lemburg added the comment: On 16.12.2014 14:38, Steve Dower wrote: > > Steve Dower added the comment: > > I justified leaving out the ABI tag in an earlier post as well as in an email > to distutils-sig, where two of the PEPs you mention were developed, and > nobody had any comment

[issue22980] C extension naming doesn't take bitness into account

2014-12-16 Thread Antoine Pitrou
Antoine Pitrou added the comment: get_platform() will be difficult to reuse, for bootstrapping reasons (you need to know the allowed extensions as soon as the interpreter starts up, or at least as soon as the first extension module may be loaded). -- __

[issue23054] ConnectionError: ('Connection aborted.', BadStatusLine(""''''"))

2014-12-16 Thread R. David Murray
R. David Murray added the comment: I wonder the actual error reported in that issue has any relationship to issue 15082? In any case, the error being presented to requests is *accurate*: httplib tried to read the status line and got nothing (the actual text in the linked issue is BadStatusLin

[issue23049] Fix functools.reduce code equivalent.

2014-12-16 Thread Antoine Pitrou
Antoine Pitrou added the comment: I agree with Raymond. Examples in the code are not meant to be a reference but, well, examples. That is, the educational value should come first and strict adherence to the language spec only second. "Roughly equivalent" is already used in the functools doc, i

[issue23054] ConnectionError: ('Connection aborted.', BadStatusLine(""''''"))

2014-12-16 Thread Martin Panter
Martin Panter added the comment: Not exactly sure what do you want the Python library to do, but perhaps this is a duplicate of Issue 8450, about making the error less misleading when the connection is closed before _any_ status line is sent. See also Issue 7427. -- nosy: +vadmium ___

[issue22980] C extension naming doesn't take bitness into account

2014-12-16 Thread Steve Dower
Steve Dower added the comment: > get_platform() will be difficult to reuse, for bootstrapping reasons ISTM that if you can't determine the value at compile time, then it doesn't matter to compilation enough to need to appear in the tag. As far as matching PEP 425 for the sake of matching it go

Re: [issue22980] C extension naming doesn't take bitness into account

2014-12-16 Thread M.-A. Lemburg
On 16.12.2014 21:28, Steve Dower wrote: > > Steve Dower added the comment: > >> get_platform() will be difficult to reuse, for bootstrapping reasons > > ISTM that if you can't determine the value at compile time, then it doesn't > matter to compilation enough to need to appear in the tag. Anto

[issue23054] ConnectionError: ('Connection aborted.', BadStatusLine(""''''"))

2014-12-16 Thread R. David Murray
R. David Murray added the comment: Ouch. I assumed the change was made to the repr, not the contents of line (I wasn't involved in that fix). Not that that would actually affect this issue, I think, since Requests doesn't want to "introspect exception objects". -- __

[issue16349] Document whether it's safe to use bytes for struct format string

2014-12-16 Thread Martin Panter
Martin Panter added the comment: Actually the “struct” module doc string seems to already hint that format strings can be byte strings: “Python bytes objects are used to hold the data representing the C struct and also as format strings . . .” -- _

[issue21071] struct.Struct.format is bytes, but should be str

2014-12-16 Thread Martin Panter
Martin Panter added the comment: It seems to me that the simplest fix is to document: 1. Struct.format attribute is a byte string 2. The input format strings for struct.pack(), Struct class, etc, are also allowed to be byte strings, for consistency (Issue 16349) Here is a patch that does that,

[issue17876] Doc issue with threading.Event

2014-12-16 Thread Martijn Pieters
Martijn Pieters added the comment: I notice that the same issue still exists in the 3.5 documentation. Surely this can at least be fixed in the development copy? -- nosy: +mjpieters ___ Python tracker

[issue23057] asyncio loop on Windows should stop on keyboard interrupt

2014-12-16 Thread STINNER Victor
STINNER Victor added the comment: Hi, I started to work on this topic a few months ago: https://code.google.com/p/tulip/issues/detail?id=191 I should update my patches. -- ___ Python tracker __

[issue23046] asyncio.BaseEventLoop is documented, but only exported via asyncio.base_events

2014-12-16 Thread STINNER Victor
STINNER Victor added the comment: I'm in favor of exposing BaseEventLoop in the asyncio namespace directly (asyncio.BaseEventLoop) because I'm using it in various asyncio projects, and I don't like having to use submodules. I consider asyncio.base_events as the private API. -- __

[issue23057] asyncio loop on Windows should stop on keyboard interrupt

2014-12-16 Thread STINNER Victor
STINNER Victor added the comment: This issue is specific to Windows. On all others platforms, signal handling is nicely supported. -- components: +Windows nosy: +steve.dower, tim.golden, zach.ware ___ Python tracker

[issue17876] Doc issue with threading.Event

2014-12-16 Thread R. David Murray
R. David Murray added the comment: If there really is an issue in the 3.4/3.5 docs, you should open an new issue explaining what the problem is. In 3.4/3.5, Event is a class, not a function, and is documented accordingly. -- ___ Python tracker

[issue22926] asyncio: raise an exception when called from the wrong thread

2014-12-16 Thread STINNER Victor
STINNER Victor added the comment: Guido wrote: > I'm okay with this approach now. I'm not sure that I understood your opinion. Are you ok to raise an exception in debug mode if call_soon() is called from a thread which has no event loop attached? (Currently, an exception is already raised in

[issue17876] Doc issue with threading.Event

2014-12-16 Thread Martijn Pieters
Martijn Pieters added the comment: Ah! Mea Culpa, you are correct. The issue is then with Python 2.7 only for which no doubt exists a separate ticket. -- ___ Python tracker ___

[issue23046] asyncio.BaseEventLoop is documented, but only exported via asyncio.base_events

2014-12-16 Thread Guido van Rossum
Guido van Rossum added the comment: OK, fine to expose the BaseEventLoop class. On Tue, Dec 16, 2014 at 3:45 PM, STINNER Victor wrote: > > > STINNER Victor added the comment: > > I'm in favor of exposing BaseEventLoop in the asyncio namespace directly > (asyncio.BaseEventLoop) because I'm using

[issue22926] asyncio: raise an exception when called from the wrong thread

2014-12-16 Thread Guido van Rossum
Guido van Rossum added the comment: Well, the PEP clearly states that get_event_loop() should never return None and raise an exception if the context has no environment. (Where context ~~ thread.) On Tue, Dec 16, 2014 at 3:48 PM, STINNER Victor wrote: > > > STINNER Victor added the comment: > >

[issue22922] asyncio: call_soon() should raise an exception if the event loop is closed

2014-12-16 Thread STINNER Victor
STINNER Victor added the comment: > Windows buildbots are not happy: test_asyncio pass again on Windows buildbots, I close the issue. -- resolution: -> fixed status: open -> closed ___ Python tracker

[issue23009] selectors.EpollSelector.select raises exception when nothing to select.

2014-12-16 Thread Roundup Robot
Roundup Robot added the comment: New changeset 1e985daa7be6 by Victor Stinner in branch 'default': Issue #23009: Skip test_selectors.test_empty_select() on Windows https://hg.python.org/cpython/rev/1e985daa7be6 -- ___ Python tracker

[issue14134] xmlrpc.client.ServerProxy needs timeout parameter

2014-12-16 Thread Demian Brecht
Demian Brecht added the comment: I think we've started to venture into system-level territory that the standard library itself shouldn't have to account for. If TCP on systems are configured by default to allow for infinite timeouts, then it should likely be an issue for those distros. I don't

[issue23046] asyncio.BaseEventLoop is documented, but only exported via asyncio.base_events

2014-12-16 Thread STINNER Victor
STINNER Victor added the comment: Here is a patch to expose BaseEventLoop. It removes Server from base_events.__all__, which means that "from asyncio.base_events import *" will no import Server anymore. Can it break real applications? -- keywords: +patch Added file: http://bugs.python.

[issue23046] asyncio.BaseEventLoop is documented, but only exported via asyncio.base_events

2014-12-16 Thread Guido van Rossum
Guido van Rossum added the comment: Sounds unlikely. If they write "from asyncio.base_events import Server" it will still work. Only if they wrote "from asyncio.base_events import *" will they be broken, and that sounds not worth worrying about. So LGTM on the patch. (But why was Server there at

[issue22926] asyncio: raise an exception when called from the wrong thread

2014-12-16 Thread STINNER Victor
STINNER Victor added the comment: 2014-12-17 0:53 GMT+01:00 Guido van Rossum : > Well, the PEP clearly states that get_event_loop() should never return None > and raise an exception if the context has no environment. (Where context ~~ > thread.) You don't reply to my question, or I misunderstood

[issue14134] xmlrpc.client.ServerProxy needs timeout parameter

2014-12-16 Thread Demian Brecht
Demian Brecht added the comment: On another note, running a simple test with against a non-routable IP yields that OSX's default timeout is 75 seconds and not 7500 seconds as the developer docs lead me to believe. -- ___ Python tracker

[issue23046] asyncio.BaseEventLoop is documented, but only exported via asyncio.base_events

2014-12-16 Thread STINNER Victor
STINNER Victor added the comment: > why was Server there at all? Tests? If you cannot answer, who can answer? :-) https://code.google.com/p/tulip/source/detail?r=f136c04d82c0 (You added Server to __all__.) I don't see any use case which needs to create explicitly a Server class. There are the c

[issue22926] asyncio: raise an exception when called from the wrong thread

2014-12-16 Thread Guido van Rossum
Guido van Rossum added the comment: Oh sorry. I'm in too much of a hurry. :-( The problem is that the thread may not have a loop, but the loop still has a tread. E.g. the tests intentionally call set_event_loop(None) to make sure that no code depends on the implict event loop. An app should be a

[issue23046] asyncio.BaseEventLoop is documented, but only exported via asyncio.base_events

2014-12-16 Thread Guido van Rossum
Guido van Rossum added the comment: Heh. Well I don't remember why I did that any more, and it doesn't seem to matter now. However the doc issue seems different than for BaseEventLoop -- Server is the *concrete* class (it actually gets instantiated, not a subclass). We could instead document the

[issue16776] Document PyCFunction_New and PyCFunction_NewEx functions

2014-12-16 Thread Martin Panter
Martin Panter added the comment: I’m far from an expert on the C API, but I was looking for a way to inspect a “builtin_function_or_method” a.k.a. PyCFunction_Type a.k.a. types.BuiltinMethodType, and ended up looking at the “Instance Method Objects” section. So maybe your functions should go n

[issue23014] Don't have importlib.abc.Loader.create_module() be optional

2014-12-16 Thread Eric Snow
Eric Snow added the comment: @Nick As long as those esoteric cases can be handled without much work via create_module and exec_module, we should have a goal in mind for yanking legacy load_module support. If there are valid use cases that can't be handled via PEP 451 then I'd say we should c

[issue23014] Don't have importlib.abc.Loader.create_module() be optional

2014-12-16 Thread Eric Snow
Eric Snow added the comment: @Brett Discussing this at PyCon sounds good. I'm in favor of dropping load_module as soon as possible (if possible), as you might have guessed by the way I implemented the module spec code. :) I agree that we should make a decision about load_module one way or t

[issue19176] DeprecationWarning for doctype() method when subclassing _elementtree.XMLParser

2014-12-16 Thread Martin Panter
Martin Panter added the comment: Since the doctype() method doesn’t appear to be removed from the “default” (3.5?) branch either, here is a patch that avoids the deprecation warning when inheriting method + a test. Hopefully this will be useful when you get some time to look at it. I’m not su

[issue23068] Add a way to determine if the current thread has the import lock

2014-12-16 Thread Guido van Rossum
New submission from Guido van Rossum: imp.lock_held() returns True if *any* thread is currently importing something. I'd like to have an API that can tell whether the *current* thread has the import lock. The implementation keeps track of this, but doesn't make the info available. Use case:

[issue634412] RFC 2387 (multipart/related) in email package

2014-12-16 Thread Martin Panter
Changes by Martin Panter : -- title: RFC 2387 in email package -> RFC 2387 (multipart/related) in email package ___ Python tracker ___ _

[issue23049] Fix functools.reduce code equivalent.

2014-12-16 Thread Roundup Robot
Roundup Robot added the comment: New changeset 0b3d69f15950 by Raymond Hettinger in branch '3.4': Issue #23049: Pure python equivalent shouldn't imply more exactitude than is really there. https://hg.python.org/cpython/rev/0b3d69f15950 -- nosy: +python-dev

[issue23049] Fix functools.reduce code equivalent.

2014-12-16 Thread Raymond Hettinger
Changes by Raymond Hettinger : -- resolution: -> fixed status: open -> closed ___ Python tracker ___ ___ Python-bugs-list mailing lis

[issue23069] IDLE's F5 Run Module doesn't transfer effects of future import

2014-12-16 Thread Raymond Hettinger
New submission from Raymond Hettinger: Future imports in a module aren't transferring to the interactive shell when executing Run Module. Given the file tmp_future.py $ cat tmp_future.py from __future__ import division, print_function print(32 / 5) Run Python inte

[issue23070] Error in Tutorial comment

2014-12-16 Thread Ross Burnett
New submission from Ross Burnett: In section "3.1.2. Strings" of the Tutorial (version 3.4 plus others?), a comment on a slicing error has an error: "word[42] # the word only has 7 characters" It should say "word[42] # the word has 6 characters" -- assignee: docs@python components:

[issue19737] Documentation of globals() and locals() should be improved

2014-12-16 Thread Martin Panter
Martin Panter added the comment: Here is a patch with my suggestion. It also now refers to _the_ dictionary rather than just _a_ dictionary, and drops the word “current”, so that it does not sound like saving a snapshot. -- keywords: +patch Added file: http://bugs.python.org/file37478/

[issue19737] Documentation of globals() and locals() should be improved

2014-12-16 Thread Martin Panter
Changes by Martin Panter : Removed file: http://bugs.python.org/file37478/globals-copy.patch ___ Python tracker ___ ___ Python-bugs-list maili

[issue19737] Documentation of globals() and locals() should be improved

2014-12-16 Thread Martin Panter
Changes by Martin Panter : Added file: http://bugs.python.org/file37479/globals-copy.patch ___ Python tracker ___ ___ Python-bugs-list mailing

[issue20059] Inconsistent urlparse/urllib.parse handling of invalid port values?

2014-12-16 Thread Martin Panter
Martin Panter added the comment: I would go for raising ValueError for port numbers out of range. The value of None was already defined to mean that no port is included in the URL. Also, the ValueError exception should be documented. It is surprising that urlsplit() does not raise any exceptio

[issue16893] Generate Idle help from Doc/library/idle.rst

2014-12-16 Thread Terry J. Reedy
Terry J. Reedy added the comment: The goal of this issue is that Idle -> Help -> IDLE Help display a good-looking, accurate help page based on Doc/library/idle.rst. The current Lib/idlelib/help.txt is neither good-looking nor accurate and must somehow be replaced, even if by temporary means,

[issue18828] urljoin behaves differently with custom and standard schemas

2014-12-16 Thread Martin Panter
Martin Panter added the comment: I think a global registry seems like overkill. Here is a patch to make urljoin() treat schemes more equally and work with arbitrary schemes automatically. I haven’t heard any arguments against this option yet, and it didn’t break any tests. Another option, sti

[issue23071] codecs.__all__ incomplete

2014-12-16 Thread Martin Panter
New submission from Martin Panter: First ones I noticed were codecs.encode() and codecs.decode(). Here is a list of other candidates, although they are not all documented, so maybe should not all be in __all__. >>> import codecs >>> public = (a for a in dir(codecs) if not a.startswith("_")) >>

[issue23071] codecs.__all__ incomplete

2014-12-16 Thread Berker Peksag
Changes by Berker Peksag : -- nosy: +berker.peksag ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail

[issue23072] 2.7.9 multiprocessing compile conflict

2014-12-16 Thread aab
New submission from aab: python-2.7.9/Modules/_multiprocessing/multiprocessing.c python-2.7.9/Modules/_multiprocessing/semaphore.c The compile lines for the above two files have "-DHAVE_SEM_OPEN=1 -DHAVE_FD_TRANSFER=1 -DHAVE_SEM_TIMEDWAIT=0" in them. The cpp code in those files uses "#ifdef"

[issue23068] Add a way to determine if the current thread has the import lock

2014-12-16 Thread Eric Snow
Eric Snow added the comment: Keep in mind that the global import lock is only held long enough to create a module-level lock. The cache of module locks is found at line 166 of Lib/importlib/_bootstrap.py and the code related to module-level locking follows. So unfortunately it won't be as si

[issue23049] Fix functools.reduce code equivalent.

2014-12-16 Thread Berker Peksag
Changes by Berker Peksag : -- stage: needs patch -> resolved ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe: ht

[issue16991] Add OrderedDict written in C

2014-12-16 Thread Eric Snow
Eric Snow added the comment: I'm open to suggestions on how to help make the patch more reviewable. Currently at roughly +2500 lines of code it's a lot to ask someone to review. While probably not the only way to help reviewers, I expect the best thing I could do is to split the patch up int

[issue14134] xmlrpc.client.ServerProxy needs timeout parameter

2014-12-16 Thread Demian Brecht
Demian Brecht added the comment: I've attached a test-less patch with my suggested approach. If there's no opposition to this change, I'll put some work into getting tests done for it as well. -- Added file: http://bugs.python.org/file37481/issue14134.patch ___

  1   2   >