[issue32576] concurrent.futures.thread deadlock due to Queue in weakref callback

2018-04-09 Thread devurandom
Change by devurandom : -- nosy: +devurandom ___ Python tracker ___ ___ Python-bugs-list

[issue21009] Potential deadlock in concurrent futures when garbage collection occurs during Queue.get

2018-04-09 Thread devurandom
Change by devurandom : -- nosy: +devurandom ___ Python tracker ___ ___ Python-bugs-list

[issue33253] xxsubtype.bench does not function correctly on CPython 3+

2018-04-09 Thread miss-islington
Change by miss-islington : -- pull_requests: +6137 ___ Python tracker ___

[issue33253] xxsubtype.bench does not function correctly on CPython 3+

2018-04-09 Thread miss-islington
Change by miss-islington : -- pull_requests: +6136 ___ Python tracker ___

[issue33253] xxsubtype.bench does not function correctly on CPython 3+

2018-04-09 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: New changeset f178028f37c9dafb72608b719eb03e5a70af4ff5 by Serhiy Storchaka (Devon R) in branch 'master': bpo-33253: Fix xxsubtype.bench() to accept correct str signature. (GH-6439)

[issue32823] Regression in test -j behavior and time in 3.7.0b1

2018-04-09 Thread Zachary Ware
Zachary Ware added the comment: Ok, interesting. The above results are from running on my Windows 8.1 buildbot, running on Azure. Running on a local fully-updated (I think) Windows 10 VM, I get results similar to what Terry reports: results come in batches of X for

[issue33248] __await__ behaves different with or without PYTHONASYNCIODEBUG

2018-04-09 Thread Jonas Obrist
Jonas Obrist added the comment: I realized I have to call __await__ of the inner coroutine object in NonTrueAwaitable.__await__. This is not a bug, but my mistake. -- resolution: -> not a bug stage: -> resolved status: open -> closed

[issue33254] importlib.resources.contents() incorrectly yields an empty list

2018-04-09 Thread Barry A. Warsaw
Barry A. Warsaw added the comment: Note that this is in the case where a user is asking for the contents of a namespace package (which by definition, can't have resources). +1 on fixing this API wart. Will you @brett.cannon will submit a PR? I'll do a quick review and

[issue33254] importlib.resources.contents() incorrectly yields an empty list

2018-04-09 Thread Brett Cannon
New submission from Brett Cannon : If you look at https://github.com/python/cpython/blob/0f914b5b5f6ba186afd7112fc851c97247076f70/Lib/importlib/resources.py#L247 you will notice that the generator for importlib.resources.contents() return an empty list. While the intent was

[issue33253] xxsubtype.bench does not function correctly on CPython 3+

2018-04-09 Thread Gorialis
Change by Gorialis : -- keywords: +patch pull_requests: +6135 stage: -> patch review ___ Python tracker ___

[issue33253] xxsubtype.bench does not function correctly on CPython 3+

2018-04-09 Thread Gorialis
New submission from Gorialis : Due to the `OS|i` signature of `xxsubtype.bench`, it accepts `bytes` as its second argument in CPython 3+, however, it does a call `PyObject_GetAttr` which only accepts `PyString`. This means that if you give the function `bytes`, it

[issue33252] Clarify ResourceWarning documentation

2018-04-09 Thread Ed Morley
New submission from Ed Morley : The `ResourceWarning` warning has always been ignored by default, since it was added in Python 3.2 in: https://github.com/python/cpython/commit/08be72d0aa0112118b79d271479598c218adfd23#diff-db4e2b9efea108a38c53e06fa99cdd77R391 However there

[issue31201] make test: module test that failed doesn't exist

2018-04-09 Thread Ned Deily
Ned Deily added the comment: Thanks for the PR, Aaron! -- resolution: -> fixed stage: patch review -> resolved status: open -> closed type: enhancement -> versions: +Python 3.6 ___ Python tracker

[issue31201] make test: module test that failed doesn't exist

2018-04-09 Thread Ned Deily
Ned Deily added the comment: New changeset 83bb39907ec3828aec6d99bb9338283bd6b30ac2 by Ned Deily (Miss Islington (bot)) in branch '3.6': [3.6] bpo-31201: Clarify command to re-run failing test(s) with example (GH-6417) (GH-6438)

[issue31201] make test: module test that failed doesn't exist

2018-04-09 Thread Ned Deily
Ned Deily added the comment: New changeset 71a3837bf39580ffa828c14247230a9277b9d5b1 by Ned Deily (Miss Islington (bot)) in branch '3.7': [3.7] bpo-31201: Clarify command to re-run failing test(s) with example (GH-6417) (GH-6437)

[issue31201] make test: module test that failed doesn't exist

2018-04-09 Thread miss-islington
Change by miss-islington : -- pull_requests: +6134 ___ Python tracker ___

[issue31201] make test: module test that failed doesn't exist

2018-04-09 Thread miss-islington
Change by miss-islington : -- pull_requests: +6133 ___ Python tracker ___

[issue31201] make test: module test that failed doesn't exist

2018-04-09 Thread Ned Deily
Ned Deily added the comment: New changeset 0f914b5b5f6ba186afd7112fc851c97247076f70 by Ned Deily (Aaron Ang) in branch 'master': bpo-31201: Clarify command to re-run failing test(s) with example (GH-6417)

[issue16974] when "python -c command" does a traceback, it open the file ""

2018-04-09 Thread Ned Deily
Change by Ned Deily : -- stage: -> needs patch versions: +Python 3.6, Python 3.7, Python 3.8 -Python 3.2, Python 3.3, Python 3.4 ___ Python tracker

[issue12345] Add math.tau

2018-04-09 Thread Pokestar Fan
Change by Pokestar Fan : -- pull_requests: +6132 ___ Python tracker ___ ___

[issue33251] ConfigParser.items returns items present in vars

2018-04-09 Thread Tim Shaffer
Change by Tim Shaffer : -- type: -> behavior ___ Python tracker ___ ___ Python-bugs-list

[issue33251] ConfigParser.items returns items present in vars

2018-04-09 Thread Tim Shaffer
New submission from Tim Shaffer : The documentation for ConfigParser.items(section, raw=False, vars=None) says the following: > Changed in version 3.2: Items present in vars no longer appear in the result. > The previous behaviour mixed actual parser options with variables

[issue33099] test_poplib hangs with the changes done in PR

2018-04-09 Thread Skip Montanaro
Skip Montanaro added the comment: @christian.heimes I figured you probably didn't need it, but I did that work before I discovered this ticket. And as a nice bonus, I got to learn git bisect. :-) -- ___ Python tracker

[issue31920] pygettext ignores directories as inputfile argument

2018-04-09 Thread Serhiy Storchaka
Change by Serhiy Storchaka : -- pull_requests: +6131 ___ Python tracker ___ ___

[issue32706] test_check_hostname() of test_ftplib started to fail randomly

2018-04-09 Thread Fred L. Drake, Jr.
Change by Fred L. Drake, Jr. : -- nosy: +fdrake ___ Python tracker ___ ___

[issue33031] Questionable code in OrderedDict definition

2018-04-09 Thread Serhiy Storchaka
Change by Serhiy Storchaka : -- resolution: -> fixed stage: patch review -> resolved status: open -> closed ___ Python tracker

[issue33031] Questionable code in OrderedDict definition

2018-04-09 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: New changeset b0f387d7ca126d486fc82744b8ec90c131230311 by Serhiy Storchaka in branch '3.7': [3.7] bpo-33031: Remove dead code in C implementation of OrderedDict. (GH-6120) (GH-6433)

[issue4963] mimetypes.guess_extension result changes after mimetypes.init()

2018-04-09 Thread David K. Hess
David K. Hess added the comment: Are there any committers watching this issue that are able to review the PR? https://github.com/python/cpython/pull/3062 It's close to 6 months old now with no action on it. I'm willing to help but doing so and then having the PR gather

[issue31920] pygettext ignores directories as inputfile argument

2018-04-09 Thread miss-islington
miss-islington added the comment: New changeset e0dbc57e116516f6ca1ef021f71e1a98773d57ed by Miss Islington (bot) in branch '3.6': bpo-31920: Fixed handling directories as arguments in the ``pygettext`` script. (GH-6259)

[issue31920] pygettext ignores directories as inputfile argument

2018-04-09 Thread miss-islington
miss-islington added the comment: New changeset 9b25bd6e26b50ade8d52a85c78d957b1f6f9131c by Miss Islington (bot) in branch '3.7': bpo-31920: Fixed handling directories as arguments in the ``pygettext`` script. (GH-6259)

[issue33099] test_poplib hangs with the changes done in PR

2018-04-09 Thread Christian Heimes
Christian Heimes added the comment: Thanks for you confirmation. I already knew which commit lead to the issue. :) The problem didn't "pop" up in my local tests or on Travis CI. I can only reproduce it locally, when I run the test in a tight loop and put extra load on the

[issue33222] Various test failures if PYTHONUSERBASE is not canonicalized

2018-04-09 Thread Akshay Sharma
Change by Akshay Sharma : -- keywords: +patch pull_requests: +6130 stage: needs patch -> patch review ___ Python tracker

[issue33031] Questionable code in OrderedDict definition

2018-04-09 Thread Serhiy Storchaka
Change by Serhiy Storchaka : -- pull_requests: +6129 ___ Python tracker ___ ___

[issue33099] test_poplib hangs with the changes done in PR

2018-04-09 Thread Skip Montanaro
Skip Montanaro added the comment: Just in case this would be useful to others, git bisect led me to this commit as the source of the problem: 61d478c71c5341cdc54e6bfb4ace4252852fd972 is the first bad commit commit 61d478c71c5341cdc54e6bfb4ace4252852fd972 Author:

[issue31920] pygettext ignores directories as inputfile argument

2018-04-09 Thread miss-islington
Change by miss-islington : -- pull_requests: +6128 ___ Python tracker ___

[issue31920] pygettext ignores directories as inputfile argument

2018-04-09 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: New changeset c93938b5beea4c3f592119ebee6d4029558db8de by Serhiy Storchaka in branch 'master': bpo-31920: Fixed handling directories as arguments in the ``pygettext`` script. (GH-6259)

[issue31920] pygettext ignores directories as inputfile argument

2018-04-09 Thread miss-islington
Change by miss-islington : -- pull_requests: +6127 ___ Python tracker ___

[issue33244] Overflow error

2018-04-09 Thread Terry J. Reedy
Terry J. Reedy added the comment: Vignesh: This issue tracker is for reporting bugs in the CPython interpreter. Requests for help with problems with your code should go elsewhere, such as pythonlist mail list or stackoverflow.com web site. In this case, your problem is

[issue33233] Suggest third-party cmd2 module as alternative to cmd

2018-04-09 Thread Ethan Furman
Change by Ethan Furman : -- nosy: +ethan.furman ___ Python tracker ___ ___

[issue33200] Optimize the empty set "literal"

2018-04-09 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: Closed due to the lack of practical applications. Can be reopened if this idiom become popular. -- resolution: -> rejected stage: patch review -> resolved status: open -> closed ___

[issue32759] multiprocessing.Array do not release shared memory

2018-04-09 Thread Antoine Pitrou
Antoine Pitrou added the comment: Yes, it's a minimal effort. More sophisticated behavior would require a more sophisticated allocator. -- ___ Python tracker

[issue33237] Improve AttributeError message for partially initialized module

2018-04-09 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: I have applied the Nick's suggestion. Needed to find a place for new test. The code is copied from PyImport_ImportModuleLevelObject(). I'm not happy from how verbose it is. And testing mod.__spec__._initialized adds relatively

[issue33222] Various test failures if PYTHONUSERBASE is not canonicalized

2018-04-09 Thread Akshay Sharma
Akshay Sharma added the comment: What are the possible cases we can have here ? -- nosy: +akshaysharma096 ___ Python tracker

[issue33031] Questionable code in OrderedDict definition

2018-04-09 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: New changeset 827d49f3cf0296f1e267eae6834a977cf312cc1e by Serhiy Storchaka in branch 'master': bpo-33031: Remove dead code in C implementation of OrderedDict. (GH-6120)

[issue32759] multiprocessing.Array do not release shared memory

2018-04-09 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: This change looks safe to me. I was just not sure that it is enough for practical cases. What if after allocating a large buffer the rest of the new area would be used for allocating small buffers? They can keep references to

[issue32759] multiprocessing.Array do not release shared memory

2018-04-09 Thread Antoine Pitrou
Antoine Pitrou added the comment: I pushed a fix for this in 3.8. Since the fix is a bit delicate, I'd rather not backport it. Thank you for reporting this issue! -- resolution: -> fixed stage: patch review -> resolved status: open -> closed

[issue32759] multiprocessing.Array do not release shared memory

2018-04-09 Thread Antoine Pitrou
Antoine Pitrou added the comment: New changeset e4679cd644aa19f9d9df9beb1326625cf2b02c15 by Antoine Pitrou in branch 'master': bpo-32759: Free unused arenas in multiprocessing.heap (GH-5827) https://github.com/python/cpython/commit/e4679cd644aa19f9d9df9beb1326625cf2b02c15

[issue33249] Unpickling objects with recursive references and partials fail due to incomplete state passed to __setstate__

2018-04-09 Thread Alexander Neumann
Alexander Neumann added the comment: Changed issue title to summarise the actual problem better. -- title: Pickling objects with recursive references and partials fail -> Unpickling objects with recursive references and partials fail due to incomplete state passed

[issue33240] shutil.rmtree fails when the inner floder is opened in Explorer on Windows

2018-04-09 Thread Eryk Sun
Eryk Sun added the comment: Your case probably isn't due to a anti-malware filesystem filter. Explorer keeps handles open to directories to get updates via ReadDirectoryChangesExW. It opens watched directories with shared delete access, so deleting the child succeeds. But

[issue33250] Move VERSION attribute output up in pydoc (via help() builtin)

2018-04-09 Thread handle
New submission from handle : I'd like to suggest moving the output of a modules version, e.g. VERSION __version__ up as it can "buried" by PACKAGE CONTENTS and DATA items. https://github.com/python/cpython/blob/3.6/Lib/pydoc.py#L1181 The other attributes (date,

[issue33249] Pickling objects with recursive references and partials fail

2018-04-09 Thread Alexander Neumann
New submission from Alexander Neumann : The code below causes a AttributeError: 'Event' object has no attribute 'name' It seems like the entries of `Machine.events` are not available during `__setstate__`. However, the behaviour depends on the Python version. For

[issue33240] shutil.rmtree fails when the inner floder is opened in Explorer on Windows

2018-04-09 Thread Yu Liu
Yu Liu added the comment: These are results on another slower machine. Note these results are attained on Windows 10, while the above on Windows 7. Just in case it has some influence. $ python test.py num_retries: 6 wait_time: 0.0008691726957804373 $

[issue26979] The danger of PyType_FromSpec()

2018-04-09 Thread Nick Coghlan
Change by Nick Coghlan : -- nosy: +ncoghlan ___ Python tracker ___ ___ Python-bugs-list

[issue32753] ssl.SSLError exceptions in test_poplib

2018-04-09 Thread INADA Naoki
INADA Naoki added the comment: On Ubuntu 17.10 (OpenSSL 1.0.2g), this patch fixes test_poplib error. But I don't know this patch is right. $ git diff diff --git a/Lib/test/test_poplib.py b/Lib/test/test_poplib.py index 6abdc93879..d7a8857b05 100644 ---

[issue33248] __await__ behaves different with or without PYTHONASYNCIODEBUG

2018-04-09 Thread Jonas Obrist
Jonas Obrist added the comment: On 9c463ec88ba21764f6fff8e01d6045a932a89438 (master/3.7) both cases fail to execute. I would argue that this code should be allowed... -- ___ Python tracker

[issue26979] The danger of PyType_FromSpec()

2018-04-09 Thread Petr Viktorin
Change by Petr Viktorin : -- nosy: +Dormouse759, encukou ___ Python tracker ___ ___

[issue15727] PyType_FromSpecWithBases tp_new bugfix

2018-04-09 Thread Petr Viktorin
Change by Petr Viktorin : -- nosy: +Dormouse759 ___ Python tracker ___ ___

[issue33012] Invalid function cast warnings with gcc 8 for METH_NOARGS

2018-04-09 Thread Siddhesh Poyarekar
Siddhesh Poyarekar added the comment: Fair enough, I'll reduce my scope of changes for this patchset, especially since I'm unable to find enough time to work on the remaining changes I had thought of in the coming weeks. I'll post an updated patch soonish.

[issue33248] __await__ behaves different with or without PYTHONASYNCIODEBUG

2018-04-09 Thread Jonas Obrist
Jonas Obrist added the comment: I've just realized the difference between the environments wasn't the operating system, but PYTHONASYNCIODEBUG. If it is set, the code works, however if it is unset the code does not work. See the updated (attached) code for reference.

[issue33099] test_poplib hangs with the changes done in PR

2018-04-09 Thread INADA Naoki
INADA Naoki added the comment: @Christian Precisely, my PR doesn't fix #32706 and #32753. It fixes only hang caused by them and print stack trace for them. -- ___ Python tracker

[issue33099] test_poplib hangs with the changes done in PR

2018-04-09 Thread Christian Heimes
Christian Heimes added the comment: This is likely a duplicate of BPO #32706 and #32753 -- nosy: +christian.heimes ___ Python tracker

[issue33248] Different behavior on macos and linux (docker) with __await__

2018-04-09 Thread Jonas Obrist
New submission from Jonas Obrist : The attached code runs fine on MacOS using 3.6.5 from homebrew. However on Windows (I tested on 3.6.4 with the 32bit installer from the website) and Linux (using the python:3.6.5 docker image) it errors with "TypeError: cannot 'yield

[issue33099] test_poplib hangs with the changes done in PR

2018-04-09 Thread INADA Naoki
INADA Naoki added the comment: There are some resource leaks: * When error occurred in setUp() function, server thread is not stopped. It leaked threads and sockets for the server. * When error occurred in server thread's run() method, asyncore.close_all() is not

[issue33099] test_poplib hangs with the changes done in PR

2018-04-09 Thread INADA Naoki
Change by INADA Naoki : -- keywords: +patch pull_requests: +6126 stage: -> patch review ___ Python tracker ___

[issue23403] Use pickle protocol 4 by default?

2018-04-09 Thread Antoine Pitrou
Antoine Pitrou added the comment: > Shelve still uses protocol 3 by default. Should it be bumped too? That sounds reasonable. Perhaps open a separate issue for it? -- ___ Python tracker

[issue33244] Overflow error

2018-04-09 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: Please provide your code and the description of your problem as plain text. -- nosy: +serhiy.storchaka ___ Python tracker

[issue33243] nltk is not working properly

2018-04-09 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: nltk is not a part of the stdlib, it a third-party library. But in this case seems the problem is in your code or configuration. Your "C:\Users\Ali Abbas\Desktop\token\token.py" file hides the standard token module. --

[issue33247] File "" is opened and read unconditionally

2018-04-09 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: This is a duplicate of issue16974. -- nosy: +serhiy.storchaka resolution: -> duplicate stage: -> resolved status: open -> closed superseder: -> when "python -c command" does a traceback, it open the file ""

[issue33247] File "" is opened and read unconditionally

2018-04-09 Thread Sławomir Nizio
New submission from Sławomir Nizio : This may lead to e.g. DoS or data leak. When an exception occurs, the Python interpreter displays the stack trace: $ python3 a.py Traceback (most recent call last): File "a.py", line 2, in print(1/0) ZeroDivisionError: division

[issue33246] Note in 18.2. json — JSON encoder and decoder is incorrect

2018-04-09 Thread INADA Naoki
INADA Naoki added the comment: > "The primary objective of this revision is to bring YAML into compliance with > JSON as an official subset." > > So it should be that YAML is a subset of JSON and not the other way around. This sentence can be read as "JSON is subset of

[issue33246] Note in 18.2. json — JSON encoder and decoder is incorrect

2018-04-09 Thread Markus Järvisalo
New submission from Markus Järvisalo : The note in https://docs.python.org/2/library/json.html section "18.2. json — JSON encoder and decoder". The note says incorrectly that JSON is a subset of YAML 1.2 but if you follow the text written in YAML 1.2 specification

[issue33240] shutil.rmtree fails when the inner floder is opened in Explorer on Windows

2018-04-09 Thread Yu Liu
Yu Liu added the comment: This time I run it a couple of consecutive times manually. The result shows that the first time it retried 12 times and the wait time was 0.0004259171330071893. Then it seems to be steady, and the num_retried is 3 or 4, and the wait_time is

[issue33245] Unable to send CTRL_BREAK_EVENT

2018-04-09 Thread Eryk Sun
Eryk Sun added the comment: Unless you're willing to step through hoops using ctypes or PyWin32, sending Ctrl+Break requires already being attached to the same console as the target. Note that the target isn't necessarily a single process that's attached to the console.