[issue31619] Strange error when convert hexadecimal with underscores to int

2017-09-28 Thread Mark Dickinson
Mark Dickinson added the comment: Looks like an overflow check that was questionable in the first place (depending on undefined behaviour), and is now both questionable and wrong. I'll see if I can find time for a fix this evening (UTC+1). -- ___ P

[issue31620] asyncio.Queue leaks memory if the queue is empty and consumers poll it frequently

2017-09-28 Thread Zack Elan
New submission from Zack Elan : Repro: Call asyncio.wait_for(some_queue.get(), some_timeout) repeatedly, with no items in the queue, so that the call times out each time. Expected: No increase in memory while polling an empty queue Actual: The queue holds on to pending "getter" futures until a

[issue31616] Windows installer: Python binaries are user-writable

2017-09-28 Thread R. David Murray
R. David Murray added the comment: I'll let Steve be the one to close this, but it sounds like this isn't even a doc bug (ie: it is standard window's practice). -- ___ Python tracker

[issue31621] Pluralization typo in Language Reference section 7.12

2017-09-28 Thread Kevin
New submission from Kevin : The documentation for the `global` statement contains the line: > CPython implementation detail: The current implementation does not enforce > some of these restriction [...] "restriction" should be "restrictions" since there is more than one of them. Attached is

[issue31616] Windows installer: Python binaries are user-writable

2017-09-28 Thread Steve Dower
Steve Dower added the comment: Correct, this is expected behavior. If you want your system to be secure *and* to modify default settings, you have to take full responsibility for that. You can't rely on other tools to have secure non-default settings (they should have secure *default* setting

[issue31621] Pluralization typo in Language Reference section 7.12

2017-09-28 Thread Mariatta Wijaya
Mariatta Wijaya added the comment: Thanks Kevin. Can you open a pull request with this change? -- nosy: +Mariatta stage: -> needs patch ___ Python tracker ___

[issue31621] Pluralization typo in Language Reference section 7.12

2017-09-28 Thread Kevin
Kevin added the comment: Yes, I intend to make a PR shortly. -- ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe

[issue31614] can't list groupby generator without breaking the sub groups generators

2017-09-28 Thread Loïc Le Loarer
Loïc Le Loarer added the comment: Thanks a lot for the clear answer, sorry for not having read the online documentation, I only read the help(itertools.groupby) which has much less details. And for my use case, I can use an explicit command just to compute the number of groups. --

[issue31621] Pluralization typo in Language Reference section 7.12

2017-09-28 Thread Kevin
Change by Kevin : -- keywords: +patch pull_requests: +3793 stage: needs patch -> patch review ___ Python tracker ___ ___ Python-bugs-

[issue31621] Pluralization typo in Language Reference section 7.12

2017-09-28 Thread Kevin
Kevin added the comment: Ok, I've created a pull request, available at https://github.com/python/cpython/pull/3809. -- ___ Python tracker ___ _

[issue31621] Pluralization typo in Language Reference section 7.12

2017-09-28 Thread Roundup Robot
Change by Roundup Robot : -- pull_requests: +3795 ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail

[issue31621] Pluralization typo in Language Reference section 7.12

2017-09-28 Thread Mariatta Wijaya
Mariatta Wijaya added the comment: New changeset 641494ec3168bd556f0af226196e13ae29bddd53 by Mariatta (Miss Islington (bot)) in branch '3.6': bpo-31621: Fix typo in Simple Statements documentation (GH-3809) (GH-3810) https://github.com/python/cpython/commit/641494ec3168bd556f0af226196e13ae29bd

[issue31621] Pluralization typo in Language Reference section 7.12

2017-09-28 Thread Mariatta Wijaya
Mariatta Wijaya added the comment: Thanks! -- resolution: -> fixed stage: patch review -> resolved status: open -> closed ___ Python tracker ___ __

[issue31158] test_pty: test_basic() fails randomly on Travis CI

2017-09-28 Thread STINNER Victor
STINNER Victor added the comment: Cornelius:Here is a PoC: I checked out your code and stressed my system with it. (...) AssertionError: ..." Did you get this failure with my PR 3802? Cornelius: "We have b'For my pet fish, Eric.\r\n' in the pty buffer. We read b'For my pet fish, Eric.\r' fro

[issue31158] test_pty: test_basic() fails randomly on Travis CI

2017-09-28 Thread STINNER Victor
STINNER Victor added the comment: Hum, let me clarify: my main goal is to get a stable CI. I don't really care of the exact implementation of one specific unit test in test_pty ;-) -- ___ Python tracker

[issue29729] RFE: uuid.UUID(bytes=...): support bytes-like types, not only bytes

2017-09-28 Thread STINNER Victor
STINNER Victor added the comment: > The code doesn't work nice with general objects supporting the buffer > protocol. The length check suppose that the value has a length, and it is the > size in bytes. The code for bytes_le suppose that the value supports slicing > and concatenating results

[issue29729] RFE: uuid.UUID(bytes=...): support bytes-like types, not only bytes

2017-09-28 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: I have tested, this doesn't affect performance. -- ___ Python tracker ___ ___ Python-bugs-list m

[issue29729] RFE: uuid.UUID(bytes=...): support bytes-like types, not only bytes

2017-09-28 Thread STINNER Victor
STINNER Victor added the comment: Serhiy: "I have tested, this doesn't affect performance." Oh, thank you for testing that :-) -- ___ Python tracker ___ __

[issue11063] Rework uuid module: lazy initialization and add a new C extension

2017-09-28 Thread Antoine Pitrou
Antoine Pitrou added the comment: New changeset a106aec2ed6ba171838ca7e6ba43c4e722bbecd1 by Antoine Pitrou in branch 'master': bpo-11063, bpo-20519: avoid ctypes and improve import time for uuid (#3796) https://github.com/python/cpython/commit/a106aec2ed6ba171838ca7e6ba43c4e722bbecd1 ---

[issue11063] Rework uuid module: lazy initialization and add a new C extension

2017-09-28 Thread Antoine Pitrou
Change by Antoine Pitrou : -- resolution: -> fixed stage: patch review -> resolved status: open -> closed ___ Python tracker ___ ___

[issue20519] Replace uuid ctypes usage with an extension module.

2017-09-28 Thread Antoine Pitrou
Antoine Pitrou added the comment: New changeset a106aec2ed6ba171838ca7e6ba43c4e722bbecd1 by Antoine Pitrou in branch 'master': bpo-11063, bpo-20519: avoid ctypes and improve import time for uuid (#3796) https://github.com/python/cpython/commit/a106aec2ed6ba171838ca7e6ba43c4e722bbecd1 ---

[issue31604] unittest.TestLoader().loadTestsFromTestCase(...) fails when adding test cases with the expectedFailure decorator

2017-09-28 Thread Krzysztof Warunek
Krzysztof Warunek added the comment: AFAIK this helper is meant to be used with test function not the TestCases. -- nosy: +kwarunek ___ Python tracker ___ _

[issue31558] gc.freeze() - an API to mark objects as uncollectable

2017-09-28 Thread STINNER Victor
STINNER Victor added the comment: I ran two benchmarks on my Fedora 26. * new = master (commit a106aec2ed6ba171838ca7e6ba43c4e722bbecd1) * ref = commit 8d59aca4a953b097a9b02b0ecafef840e4ac5855 git co master ./python -m perf timeit -s 'import sys, uuid' "del sys.modules['uuid']; import uuid; u

[issue11063] Rework uuid module: lazy initialization and add a new C extension

2017-09-28 Thread STINNER Victor
STINNER Victor added the comment: I ran two benchmarks on my Fedora 26. * new = master (commit a106aec2ed6ba171838ca7e6ba43c4e722bbecd1) * ref = commit 8d59aca4a953b097a9b02b0ecafef840e4ac5855 git co master ./python -m perf timeit -s 'import sys, uuid' "del sys.modules['uuid']; import uuid; u

[issue31558] gc.freeze() - an API to mark objects as uncollectable

2017-09-28 Thread STINNER Victor
Change by STINNER Victor : -- Removed message: https://bugs.python.org/msg303283 ___ Python tracker ___ ___ Python-bugs-list mailing

[issue31558] gc.freeze() - an API to mark objects as uncollectable

2017-09-28 Thread STINNER Victor
STINNER Victor added the comment: (my previous msg303283 was for the bpo-11063, I removed it, sorry for the spam.) -- ___ Python tracker ___ ___

[issue31158] test_pty: test_basic() fails randomly on Travis CI

2017-09-28 Thread Cornelius Diekmann
Cornelius Diekmann added the comment: Yes, I get the AssertionError with the latest version of PR 3802. From the high load avg of my system, you can see that the error occurs very rarely and that I need to stress my system to trigger it. With PR 3802, the error occurs way less frequently than

[issue25351] pyvenv activate script failure with specific bash option

2017-09-28 Thread R. David Murray
R. David Murray added the comment: Note that in the equivalent issue raised against virtualenv, the concern was raised that some old sh-like shells might not support this syntax, but it was pointed out that it is part of the posix standard. I'm not arguing for or against here, just noting re

[issue11063] Rework uuid module: lazy initialization and add a new C extension

2017-09-28 Thread Antoine Pitrou
Antoine Pitrou added the comment: Crude import benchmark (Ubuntu): * before: $ time ./python -c "import uuid" real0m0.074s user0m0.056s sys 0m0.012s * after: $ time ./python -c "import uuid" real0m0.030s user0m0.028s sys 0m0.000s * baseline: $ time ./python -c pas

[issue25351] pyvenv activate script failure with specific bash option

2017-09-28 Thread Sorin Sbarnea
Sorin Sbarnea added the comment: Based on my tests this worked with all shells I tested with, the syntax being a very old one and not some new/modern one. Passed: bash, zsh, dash, ksh Platforms: MacOS, RHEL Linux Failed with: tcsh but with the note that even the original code would fail with

[issue31620] asyncio.Queue leaks memory if the queue is empty and consumers poll it frequently

2017-09-28 Thread Surenkumar Nihalani
Surenkumar Nihalani added the comment: I am working on fixing this. -- nosy: +snihalani ___ Python tracker ___ ___ Python-bugs-list

[issue31622] Make threading.get_ident() return an opaque type

2017-09-28 Thread pdox
New submission from pdox : Currently, Python exposes "thread identifiers" as unsigned long values across multiple modules: threading.get_ident() -> Returns an integer thread id sys._current_frames() -> Dictionary keys are integer thread ids signal.pthread_kill() -> Accepts an arbitrary integer

[issue31623] Allow to build MSI installer from the official tarball

2017-09-28 Thread Ivan Pozdeev
New submission from Ivan Pozdeev : Since the last version of 3.4 is only made available as a source tarball, it's imperative to be able to make a distributable package locally from it. Tools/msi/msi.py only works from an `hg' checkout. -- components: Build messages: 303292 nosy: Ivan.P

[issue31622] Make threading.get_ident() return an opaque type

2017-09-28 Thread R. David Murray
R. David Murray added the comment: Are you aware of PEP 539? (See issue 25658 for discussion.) I haven't followed that closely, but I imagine this issue is at least related. -- nosy: +r.david.murray ___ Python tracker

[issue31623] Allow to build MSI installer from the official tarball

2017-09-28 Thread R. David Murray
R. David Murray added the comment: Assuming 3.4 is packagable using msi and hg is the only problem, I presume you could use an hg-git adapter to get an hg checkout to build from. -- nosy: +r.david.murray ___ Python tracker

[issue31623] Allow to build MSI installer from the official tarball

2017-09-28 Thread Ivan Pozdeev
Change by Ivan Pozdeev : -- keywords: +patch nosy: -r.david.murray Added file: https://bugs.python.org/file47176/0001-Support-making-MSI-installer-from-tarball.patch ___ Python tracker __

[issue31623] Allow to build MSI installer from the official tarball

2017-09-28 Thread Ivan Pozdeev
Change by Ivan Pozdeev : -- nosy: +r.david.murray ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail

[issue31623] Allow to build MSI installer from the official tarball

2017-09-28 Thread Ivan Pozdeev
Ivan Pozdeev added the comment: With this patch, I managed to make a working installer. There's nothing in PCBuild/readme.txt about making an installer, and this is the only relevant tool I found in the source. If there's another, feel free to close the ticket, and I'll create another one to

[issue31624] remove support for BSD/OS

2017-09-28 Thread Benjamin Peterson
New submission from Benjamin Peterson : This operating system hasn't been supported by its vendor since 2004. We should get rid of our code for it. -- components: Build messages: 303296 nosy: benjamin.peterson priority: normal severity: normal status: open title: remove support for BSD/

[issue31624] remove support for BSD/OS

2017-09-28 Thread Benjamin Peterson
Change by Benjamin Peterson : -- keywords: +patch pull_requests: +3796 stage: -> patch review ___ Python tracker ___ ___ Python-bugs

[issue31603] Please add argument to override stdin/out/err in the input builtin

2017-09-28 Thread Wren Turkal
Wren Turkal added the comment: Added a PR to facilitate discussion on python-ideas. -- keywords: +patch pull_requests: +3798 stage: -> patch review ___ Python tracker ___

[issue31620] asyncio.Queue leaks memory if the queue is empty and consumers poll it frequently

2017-09-28 Thread Surenkumar Nihalani
Change by Surenkumar Nihalani : -- keywords: +patch pull_requests: +3797 stage: -> patch review ___ Python tracker ___ ___ Python-bu

[issue31285] a SystemError and an assertion failure in warnings.warn_explicit()

2017-09-28 Thread Oren Milman
Oren Milman added the comment: Another thought - the existing code assumes that splitlines() returned a string. So maybe we could just check that get_source() returned a string, and then call the method str.splitlines() on it? -- ___ Python tracker

[issue31624] remove support for BSD/OS

2017-09-28 Thread Benjamin Peterson
Benjamin Peterson added the comment: New changeset 288d1daadaddf6ae35cf666138ba4b5d07449657 by Benjamin Peterson in branch 'master': remove support for BSD/OS (closes bpo-31624) (#3812) https://github.com/python/cpython/commit/288d1daadaddf6ae35cf666138ba4b5d07449657 -- resolution:

[issue31285] a SystemError and an assertion failure in warnings.warn_explicit()

2017-09-28 Thread Oren Milman
Oren Milman added the comment: oh, of course, checking that get_source() returned a string before passing it to str.splitlines() is not needed. -- ___ Python tracker ___ __

[issue31625] stop using ranlib

2017-09-28 Thread Benjamin Peterson
New submission from Benjamin Peterson : As far as I'm aware, every modern *nix's ar supports an "s" flag that removes the need to run ranlib separately on a a static library. We should just do that and stop running ranlib. That saves us some lines in configure.ac and the Makefile. --

[issue31625] stop using ranlib

2017-09-28 Thread Benjamin Peterson
Change by Benjamin Peterson : -- keywords: +patch pull_requests: +3799 stage: -> patch review ___ Python tracker ___ ___ Python-bugs

[issue31626] Crash in _PyUnicode_DecodeUnicodeEscape on OpenBSD

2017-09-28 Thread Serhiy Storchaka
New submission from Serhiy Storchaka : I tried to build CPython on 64-bit OpenBSD. It was built successfully, but tests crash. They crash on importing hashlib. Actually on compiling hashlib docstring. Minimal reproducer is: $ ./python -c 'import codecs; codecs.decode(r"\\"*15 + "x"*1906, "uni

[issue31285] a SystemError and an assertion failure in warnings.warn_explicit()

2017-09-28 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: What if get_source() returned a unicode string? Usually it returns 8-bit string, but in many cases unicode is accepted if str is expected, so you need to check this option too. -- ___ Python tracker

[issue31626] Crash in _PyUnicode_DecodeUnicodeEscape on OpenBSD

2017-09-28 Thread Serhiy Storchaka
Change by Serhiy Storchaka : -- type: -> crash ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.p

<    1   2