[issue24580] Wrong or missing exception when compiling regexes with recursive named backreferences

2015-07-06 Thread Serhiy Storchaka
Changes by Serhiy Storchaka : -- assignee: -> serhiy.storchaka nosy: +serhiy.storchaka stage: -> needs patch versions: +Python 3.5, Python 3.6 ___ Python tracker ___ __

[issue24579] Additional tests for urllib module

2015-07-06 Thread Craig Northway
Craig Northway added the comment: Whoops, looks like there is definitely some redundancy. I didn't notice those tests at the time I wrote these (PyCon AU last year) and while I have been grappling with getting permission to make the contributions it looks like it's been worked on a bit. I'll

[issue24580] Wrong or missing exception when compiling regexes with recursive named backreferences

2015-07-06 Thread Dan Haffey
New submission from Dan Haffey: Error reporting for recursive backreferences in regexes isn't consistent across both types of backref. Here's the exception for a recursive numeric backref: >>> import re >>> re.compile(r'(\1)') Traceback (most recent call last): ... sre_constants.error: cann

[issue24579] Additional tests for urllib module

2015-07-06 Thread Martin Panter
Martin Panter added the comment: Have you seen the existing test cases in /Lib/test/test_urlparse.py? If not, I don’t blame you, because of the odd test file naming and structuring. :) But I suspect some of your tests may be redundant. But you might be in a good position to suggest some commen

[issue13456] Providing a custom HTTPResponse class to HTTPConnection

2015-07-06 Thread Martin Panter
Martin Panter added the comment: Why do people want “response_class” to be part of the API? If so, more details about it may need to added, e.g. the following methods and attributes seem to be required: _read_status(), fp, close(), isclosed(), begin() and will_close. The “debuglevel” attribute

[issue24573] Using multiprocessing with tkinter frames in Python 3.4.3 crashes in OS X

2015-07-06 Thread Topher Kessler
Topher Kessler added the comment: Yeah it is a bug in OS X, fixed by setting the python multiprocessing start method to 'forkserver' instead of the default fork. -- ___ Python tracker _

[issue24579] Additional tests for urllib module

2015-07-06 Thread Craig Northway
Changes by Craig Northway : -- versions: +Python 3.6 ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe: https://ma

[issue24579] Additional tests for urllib module

2015-07-06 Thread Craig Northway
Changes by Craig Northway : -- keywords: +patch Added file: http://bugs.python.org/file39877/urllib.patch ___ Python tracker ___ ___ P

[issue24579] Additional tests for urllib module

2015-07-06 Thread Craig Northway
New submission from Craig Northway: Patch containing additional tests for urllib module to increase code coverage for url parsing. Current coverage: Lib/urllib/parse 51320261% Updated coverage: Lib/urllib/parse 51313973% -- components:

[issue24079] xml.etree.ElementTree.Element.text does not conform to the documentation

2015-07-06 Thread Martin Panter
Changes by Martin Panter : -- stage: patch review -> commit review ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscrib

[issue24136] document PEP 448: unpacking generalization

2015-07-06 Thread Martin Panter
Martin Panter added the comment: Yes I think it is expected and documented that the leftovers are turned into a list. See . I originally had similar confusion, expectating the starred target to become a tuple, because people ofte

[issue4356] Add "key" argument to "bisect" module functions

2015-07-06 Thread Raymond Hettinger
Raymond Hettinger added the comment: I'll add a key= variant for Python 3.6. -- versions: +Python 3.6 -Python 3.4 ___ Python tracker ___ __

[issue24578] [RFE] Add asyncio.wait_for_result API

2015-07-06 Thread Martin Panter
Martin Panter added the comment: I don’t think you need the __await__() call. Just do loop.run_until_complete(awaitable). I understand “asyncio” doesn’t support recursive calls into the same event loop on purpose; see Issue 22239. So this code would only be useful from outside of the event lo

[issue23275] Can assign [] = (), but not () = []

2015-07-06 Thread Martin Panter
Martin Panter added the comment: I welcome this patch to go ahead. But the documentation also needs updating (see original post). I think it should mention that “target_list” can be empty. And it should use “iterab

[issue24136] document PEP 448

2015-07-06 Thread Konstantin Molchanov
Konstantin Molchanov added the comment: Hi! I'd like to update the docs with the examples of the new syntax usage. This is my first contribution to the Python docs, so I'd like to ask for some assistance. I'm going to start with adding an example to the tutorial (https://docs.python.org/3.5/

[issue24576] python27 unicode align comments

2015-07-06 Thread Ned Deily
Ned Deily added the comment: Thanks for the patch. However, in general, we don't like to change the source files in Python just to improve white-space formatting, in particular with older releases like Python 2.7. If the formatting changes are being done as part of a larger change in the are

[issue20154] Deadlock in asyncio.StreamReader.readexactly() (fix applied, need unit test)

2015-07-06 Thread STINNER Victor
STINNER Victor added the comment: I don't see anyone motivated to write a complex unit test for the issue which is already fixed, so I close the issue. Thanks for the fix Guido. -- resolution: remind -> fixed status: open -> closed ___ Python tracker

[issue24573] Using multiprocessing with tkinter frames in Python 3.4.3 crashes in OS X

2015-07-06 Thread Ronald Oussoren
Ronald Oussoren added the comment: This is likely a known issue with using os.fork on OSX: that is unsafe, and likely causes crashes, once one of Apple's frameworks has initialized. I think it might be better in the long run to make multiprocessing on OSX behave the same as on windows, but ha

[issue24573] Using multiprocessing with tkinter frames in Python 3.4.3 crashes in OS X

2015-07-06 Thread Ned Deily
Ned Deily added the comment: A web search will find multiple hits for problems with using Tk (and Tkinter) with multiprocess on OS X and elsewhere. On OS X, there is a well-known and documented restriction that impacts Tk-based apps: "When launching separate processes using the fork function,

[issue24570] IDLE Autocomplete and Call Tips Do Not Pop Up on OS X with ActiveTcl 8.5.18

2015-07-06 Thread Ned Deily
Ned Deily added the comment: Kevin, I think that Autocomplete is implemented as an IDLE extension in: Lib/idlelib/AutoComplete.py Lib/idlelib/AutoCompleteWindow.py and configured in: Lib/idlelib/config-extensions.def -> force-open-completions= Perhaps someone could try to reduce it to smaller t

[issue24571] [RFE] Add asyncio.blocking_call API

2015-07-06 Thread Sven R. Kunze
Sven R. Kunze added the comment: 2 remarks: 1) I would rather go for a more comprehensible name such as 'get_awaitable' instead of 'blocking_call'. Later reminds me of the execution of f which is not the case. 2) redundant ) in the end of """Usage: result = await asyncio.blocking_call(f, *ar

[issue24571] [RFE] Add asyncio.blocking_call API

2015-07-06 Thread Sven R. Kunze
Sven R. Kunze added the comment: Thanks for taking the initiative here, Nick. I created a follow-up on this: http://bugs.python.org/issue24578 In order to bridge both worlds, projects might need convenient way from and to either world (classic and asyncio). -- components: +asyncio nos

[issue24578] [RFE] Add asyncio.wait_for_result API

2015-07-06 Thread Sven R. Kunze
Changes by Sven R. Kunze : -- nosy: +srkunze ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.pytho

[issue24578] [RFE] Add asyncio.wait_for_result API

2015-07-06 Thread Sven R. Kunze
Changes by Sven R. Kunze : -- nosy: +giampaolo.rodola, ncoghlan, pitrou -srkunze type: -> enhancement ___ Python tracker ___ ___ Pyth

[issue24578] [RFE] Add asyncio.wait_for_result API

2015-07-06 Thread Sven R. Kunze
New submission from Sven R. Kunze: In order to complement http://bugs.python.org/issue24571, this is another high-level convenience API for asyncio to treat an awaitable like a usual subroutine (credits go to Nick Coghlan): # Call awaitable from synchronous code def wait_for_result(awa

[issue17311] use distutils terminology in "PyPI package display" section

2015-07-06 Thread sanad
sanad added the comment: In an attempt to fix this issue on lines of the criteria given by nick, have uploaded my patch . Please review it so that If mistake is there ,I can fix and upload corrected patch again. Thanks for your time. -- keywords: +patch nosy: +sanad Added file: http://

[issue4356] Add "key" argument to "bisect" module functions

2015-07-06 Thread Mark Dickinson
Mark Dickinson added the comment: I've just encountered another case where the lack of a key on bisect has led to more complicated and error-prone code than necessary. Quick summary: we've got a list containing an ordered collection of non-overlapping open intervals on the real line. (In case

[issue24577] Document asyncio behavior (logging and call to connection_lost) on socket TimeoutError

2015-07-06 Thread R. David Murray
Changes by R. David Murray : -- title: Document behavior (logging and call to connection_lost) on socket TimeoutError -> Document asyncio behavior (logging and call to connection_lost) on socket TimeoutError ___ Python tracker

[issue24577] Document behavior (logging and call to connection_lost) on socket TimeoutError

2015-07-06 Thread R. David Murray
Changes by R. David Murray : -- assignee: -> docs@python components: +Documentation, asyncio nosy: +docs@python, gvanrossum, haypo, yselivanov stage: -> needs patch type: -> behavior versions: +Python 3.4, Python 3.5, Python 3.6 ___ Python tracker

[issue24577] Document behavior (logging and call to connection_lost) on socket TimeoutError

2015-07-06 Thread R. David Murray
New submission from R. David Murray: I saw _fatal_error tracebacks in my application log, and thought I had hit an asyncio bug, but according to https://github.com/python/asyncio/issues/135 this is the correct behavior. That issue ends with a request to open a documentation issue on the pytho

[issue24575] timemodule build fail - missing definitions for _Py_BEGIN_SUPPRESS_IPH and _Py_END_SUPPRESS_IPH

2015-07-06 Thread Timothy Murphy
Timothy Murphy added the comment: Ok so I see the compiler is including pyport.h (using strace) so that means that it can only be a case of Py_BUILD_CORE not being in CFLAGS for timemodule.o. I suppose that this is a configure problem. I'll try to work out how/why. -- _

[issue24575] timemodule build fail - missing definitions for _Py_BEGIN_SUPPRESS_IPH and _Py_END_SUPPRESS_IPH

2015-07-06 Thread Timothy Murphy
Timothy Murphy added the comment: I'm so sorry. I apologise for mucking up and giving you the wrong changeset :-( my hg summary output is as follows: parent: 96850:5adf995d443f Issue #18684: Fixed reading out of the buffer in the re module. branch: 3.5 commit: 2 unknown (clean) update: (curre

[issue24575] timemodule build fail - missing definitions for _Py_BEGIN_SUPPRESS_IPH and _Py_END_SUPPRESS_IPH

2015-07-06 Thread Steve Dower
Steve Dower added the comment: Last time this came up the solution was either "hg purge" or "make distclean", I don't remember which worked. timemodule.c should already be built with Py_BUILD_CORE set in CFLAGS, but apparently it's possible for that setting to disappear from one of the genera

[issue24567] random.choice IndexError due to double-rounding

2015-07-06 Thread Tim Peters
Tim Peters added the comment: Mark, closest I could find to a substantive SSE-vs-fsum report is here, but it was closed (because the fsum tests were changed to ignore the problem ;-) ): http://bugs.python.org/issue5593 -- ___ Python tracker

[issue24575] timemodule build fail - missing definitions for _Py_BEGIN_SUPPRESS_IPH and _Py_END_SUPPRESS_IPH

2015-07-06 Thread R. David Murray
R. David Murray added the comment: It works for us. I've added Steve Dower to nosy, who I believe added that code. IIUC it should only come into play on Windows. Are you using a stock checkout, or have you applied local modifications? The changeset id you reference doesn't have IPH in it.

[issue24574] ANSI escape sequences breaking string justification

2015-07-06 Thread R. David Murray
R. David Murray added the comment: See issue 12499 for an RFE to textwrap that would at least partially address this use case. -- nosy: +r.david.murray ___ Python tracker ___ __

[issue24567] random.choice IndexError due to double-rounding

2015-07-06 Thread Mark Dickinson
Mark Dickinson added the comment: > Still, I think we could switch to -mfpmath=sse, which would at least guarantee consistent behavior across different gcc versions. ... which would fix fsum on 32-bit Linux, too. (I thought there was an open issue for this, but now I can't find it.) -

[issue24573] Using multiprocessing with tkinter frames in Python 3.4.3 crashes in OS X

2015-07-06 Thread R. David Murray
R. David Murray added the comment: Your test code works for me on linux and python3.3 and 3.4.1. That is, I can click four buttons and get back the prompt, with no segfault. It is quite possible this is a bug in the Mac version of TK, assuming this is even supposed to work. -- nosy:

[issue18295] Possible integer overflow in PyCode_New()

2015-07-06 Thread Mark Lawrence
Mark Lawrence added the comment: Could we try and get this closed please, as I'm always a little concerned that a code change causes a genuine warning that should be actioned, but it gets masked by all the others. -- ___ Python tracker

[issue24576] python27 unicode align comments

2015-07-06 Thread 潘新明
New submission from 潘新明: see patch. -- components: Unicode files: python27_unicode_align_comments.patch keywords: patch messages: 246360 nosy: ezio.melotti, haypo, 潘新明 priority: normal severity: normal status: open title: python27 unicode align comments versions: Python 2.7 Added file:

[issue24575] timemodule build fail - missing definitions for _Py_BEGIN_SUPPRESS_IPH and _Py_END_SUPPRESS_IPH

2015-07-06 Thread Timothy Murphy
Timothy Murphy added the comment: This patch works for me on Linux but it seems clearly wrong for windows. The problem is that using it on windows introduces a dependency and I don't have a windows machine to check if this is ok. To me it seems that the time module must have been built as par

[issue24575] timemodule build fail - missing definitions for _Py_BEGIN_SUPPRESS_IPH and _Py_END_SUPPRESS_IPH

2015-07-06 Thread Timothy Murphy
New submission from Timothy Murphy: My build of the 3.5 head fails in timemodule.c which results in an interpreter that can run but can't "import time". Details: changeset 96851:bb9fc884a838 on Fedora Linux x86_64 Output: /home/tim/build/cpython/Modules/timemodule.c: In function ‘time_strftim

[issue24574] ANSI escape sequences breaking string justification

2015-07-06 Thread Eric V. Smith
Eric V. Smith added the comment: strings are unaware of any ANSI escape sequences or other structure that is being ascribed to their contents. The '\033' escape character is being counted, as are the rest of the characters in that string. Since the string is already at least 10 characters long

[issue18684] Pointers point out of array bound in _sre.c

2015-07-06 Thread Serhiy Storchaka
Changes by Serhiy Storchaka : -- resolution: -> fixed stage: commit review -> resolved status: open -> closed ___ Python tracker ___

[issue18684] Pointers point out of array bound in _sre.c

2015-07-06 Thread Roundup Robot
Roundup Robot added the comment: New changeset 0007031e0452 by Serhiy Storchaka in branch '2.7': Issue #18684: Fixed reading out of the buffer in the re module. https://hg.python.org/cpython/rev/0007031e0452 New changeset 389795b7c703 by Serhiy Storchaka in branch '3.4': Issue #18684: Fixed read

[issue24551] byte conversion

2015-07-06 Thread Padmanabhan Tr
Padmanabhan Tr added the comment: Dear Mr Steven D'ApranoThanks for your prompt response.I guess that 'b'\x00\x00 0' is the same as b'\x00\x00\x20\x30' if we take (space) as 20 & 0 as 30 as with ASCII / UTF-8 representation.  But if I go by 'Python Library Reference -Release version 3.4.2 (Sec

[issue24566] Unsigned Integer Overflow in sre_lib.h

2015-07-06 Thread Serhiy Storchaka
Changes by Serhiy Storchaka : -- Removed message: http://bugs.python.org/msg246353 ___ Python tracker ___ ___ Python-bugs-list mailing

[issue24566] Unsigned Integer Overflow in sre_lib.h

2015-07-06 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: Yes, this patch was not applied because it had no visible effect on Linux. Now, with your report, there is a case on Windows. -- ___ Python tracker _

[issue24566] Unsigned Integer Overflow in sre_lib.h

2015-07-06 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: Yes, this patch was not applied because it had no visible effect on Linux. No, with your report, there is a case on Windows. -- assignee: -> serhiy.storchaka resolution: -> duplicate stage: -> resolved status: open -> closed superseder: -> Pointer

[issue24567] random.choice IndexError due to double-rounding

2015-07-06 Thread Stefan Krah
Stefan Krah added the comment: > Python-the-language makes no promises about adhering to IEEE 754 arithmetic > rule. Still, I think we could switch to -mfpmath=sse, which would at least guarantee consistent behavior across different gcc versions. -- ___

[issue24574] ANSI escape sequences breaking string justification

2015-07-06 Thread Krzysztof Słychań
New submission from Krzysztof Słychań: Strings containing ANSI escape sequences are not justified if the length including escape sequences exceeds the field width. Testcase: Let's make a string with escape sequences - bold, for example: >>> string = '\033[01m' + 'bold' + '\033[0m' String lengt

[issue24259] tar.extractall() does not recognize unexpected EOF

2015-07-06 Thread Lars Gustäbel
Changes by Lars Gustäbel : -- resolution: -> fixed stage: patch review -> resolved status: open -> closed ___ Python tracker ___ ___

[issue24259] tar.extractall() does not recognize unexpected EOF

2015-07-06 Thread Roundup Robot
Roundup Robot added the comment: New changeset 372aa98eb72e by Lars Gustäbel in branch '2.7': Issue #24259: tarfile now raises a ReadError if an archive is truncated inside a data segment. https://hg.python.org/cpython/rev/372aa98eb72e New changeset c7f4f61697b7 by Lars Gustäbel in branch '3.4'