[issue33560] tuple.index() could return a more explicit error message

2018-05-17 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: This is a duplicate of issue13349. -- nosy: +serhiy.storchaka resolution: -> fixed stage: patch review -> resolved status: open -> closed superseder: -> Non-informative error message in index() and remove() functions ___

[issue33548] tempfile._candidate_tempdir_list should consider common TEMP locations

2018-05-17 Thread Steve Dower
Steve Dower added the comment: Merged as part of the VSTS PR (it was needed to fix some tests on the Windows build machine) -- resolution: -> fixed stage: patch review -> resolved status: open -> closed ___ Python tracker

[issue33558] Python has no icon in taskbar and in start screen

2018-05-17 Thread Serhiy Storchaka
Change by Serhiy Storchaka : -- assignee: -> terry.reedy components: +IDLE, Windows nosy: +paul.moore, steve.dower, terry.reedy, tim.golden, zach.ware type: performance -> behavior versions: +Python 3.6 -Python 3.5 ___ Python tracker

[issue32604] Expose the subinterpreters C-API in Python for testing use.

2018-05-17 Thread Yury Selivanov
Change by Yury Selivanov : -- nosy: -yselivanov ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.

[issue33561] Add .tostring() method to xml.etree.ElementTree.Element

2018-05-17 Thread Steven Vascellaro
New submission from Steven Vascellaro : In Python 3.6, converting an xml `xml.etree.ElementTree.Element` to a string is done using `xml.etree.ElementTree.tostring()`. ``` from xml.etree import ElementTree xml = ElementTree.Element('Person', Name='John') print(ElementTree.tostring(xml, encoding

[issue33555] No SyntaxError raised for `return` with argument inside generator

2018-05-17 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: See also What’s New In Python 3.3: https://docs.python.org/3/whatsnew/3.3.html#pep-380-syntax-for-delegating-to-a-subgenerator And PEP 380 itself. -- ___ Python tracker _

[issue32604] Expose the subinterpreters C-API in Python for testing use.

2018-05-17 Thread Emily Morehouse
Change by Emily Morehouse : -- nosy: +emilyemorehouse ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe: https://

[issue33561] Add .tostring() method to xml.etree.ElementTree.Element

2018-05-17 Thread Steven Vascellaro
Steven Vascellaro added the comment: Alternatively, the most intuitive solution would be to give `Element` an explicit `__str__` method. The current behavior of `str(Element)` is to return the object's location in memory. ``` from xml.etree import ElementTree xml = ElementTree.Element('Pers

[issue33559] Exception's repr change not documented

2018-05-17 Thread miss-islington
Change by miss-islington : -- pull_requests: +6613 ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe: https://mai

[issue33559] Exception's repr change not documented

2018-05-17 Thread Steve Dower
Steve Dower added the comment: New changeset 631753fcc5e88bbbad402933e77295675cfe1fee by Steve Dower (Miro Hrončok) in branch 'master': bpo-33559: Document changed repr of exceptions (GH-6943) https://github.com/python/cpython/commit/631753fcc5e88bbbad402933e77295675cfe1fee -- nosy:

[issue33355] Windows 10 buildbot: 15 min timeout on test_mmap.test_large_filesize()

2018-05-17 Thread Paul Goins
Paul Goins added the comment: Also, to be clear, I understand what David is saying and don't disagree at all. And if this really is Spectre related, it may be difficult to "go back" and test a before case, so my last comment about "digging in" may be rather moot. Does tweaking the timeout so

[issue33559] Exception's repr change not documented

2018-05-17 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: This was done in issue30399, and I was not sure that this change is worth adding in What's New. Add a reference to the issue. -- nosy: +serhiy.storchaka ___ Python tracker ___

[issue33559] Exception's repr change not documented

2018-05-17 Thread Miro Hrončok
Change by Miro Hrončok : -- pull_requests: +6614 ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.

[issue33559] Exception's repr change not documented

2018-05-17 Thread Miro Hrončok
Miro Hrončok added the comment: I was bit by this, so that's why I think this is worth documenting. https://github.com/testing-cabal/testtools/issues/270 -- ___ Python tracker ___

[issue33559] Exception's repr change not documented

2018-05-17 Thread Steve Dower
Steve Dower added the comment: It's worth documenting. I'll merge the next PR with the attribution. -- ___ Python tracker ___ ___ Py

[issue33561] Add .tostring() method to xml.etree.ElementTree.Element

2018-05-17 Thread Stefan Behnel
Stefan Behnel added the comment: Sorry, but you are proposing an API extension here that provides no benefits but duplicates existing functionality in a less versatile place. This is not going to happen. The second proposal (str(xml)) is actually not very helpful as it does not allow any kin

[issue33559] Exception's repr change not documented

2018-05-17 Thread Steve Dower
Steve Dower added the comment: New changeset 54fc49737a6a79f6e2ece16e22b233858b836567 by Steve Dower (Miss Islington (bot)) in branch '3.7': bpo-33559: Document changed repr of exceptions (GH-6943) (GH-6950) https://github.com/python/cpython/commit/54fc49737a6a79f6e2ece16e22b233858b836567 --

[issue33554] Optimize PyDictObject

2018-05-17 Thread b@n
b@n added the comment: A little performance optimization, but I think the key is not in performance optimization. The semantics of the dictresize function are not uniform, and it is inconvenient for others to read. The dictresize function should be split to make it just resize. What do you th

[issue33559] Exception's repr change not documented

2018-05-17 Thread Steve Dower
Steve Dower added the comment: New changeset fb9dd8915314d857161de89fcbbb041f2b49fc22 by Steve Dower (Miro Hrončok) in branch 'master': bpo-33559: Attribute changed repr of exceptions (GH-6954) https://github.com/python/cpython/commit/fb9dd8915314d857161de89fcbbb041f2b49fc22 --

[issue25478] Consider adding a normalize() method to collections.Counter()

2018-05-17 Thread Allen Downey
Allen Downey added the comment: I'd like to second Raymond's suggestion. With just a few additional methods, you could support a useful set of operations. One possible API: def scaled(self, factor) """Returns a new Counter with all values multiplied by factor.""" def normalized(self, total=

[issue33559] Exception's repr change not documented

2018-05-17 Thread miss-islington
Change by miss-islington : -- pull_requests: +6615 ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe: https://mai

[issue33558] Python has no icon in taskbar and in start screen

2018-05-17 Thread Terry J. Reedy
Terry J. Reedy added the comment: For me, 3.6.5 IDLE has the same Python app icon (white notebook page with blue/yellow snakes) as always. But I upgraded from 3.6.4, etc, so my Win10 machine already had the icon. Filip, which Windows (in case it makes a difference)? Which *exact* installer

[issue25478] Consider adding a normalize() method to collections.Counter()

2018-05-17 Thread Vedran Čačić
Vedran Čačić added the comment: As I said above, if we're going to go down that route, it seems much more reasonable to me that total should be a cached property, that's updated on every Counter update (in __setitem__, increased by a difference of a new value and an old one for that key). An

[issue33559] Exception's repr change not documented

2018-05-17 Thread miss-islington
miss-islington added the comment: New changeset efa642779739b5af028b0f6ebb9033395e124273 by Miss Islington (bot) in branch '3.7': bpo-33559: Attribute changed repr of exceptions (GH-6954) https://github.com/python/cpython/commit/efa642779739b5af028b0f6ebb9033395e124273 -- nosy: +miss

[issue12486] tokenize module should have a unicode API

2018-05-17 Thread Matthias Bussonnier
Matthias Bussonnier added the comment: > Why not just bless the existing generate_tokens() function as a public API, Yes please, or just make the private `_tokenize` public under another name. The `tokenize.tokenize` method try to magically detect encoding which may be unnecessary.

[issue12486] tokenize module should have a unicode API

2018-05-17 Thread Thomas Kluyver
Change by Thomas Kluyver : -- pull_requests: +6616 ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe: https://mai

[issue9969] tokenize: add support for tokenizing 'str' objects

2018-05-17 Thread Thomas Kluyver
Thomas Kluyver added the comment: I've opened a PR for issue #12486, which would make the existing but undocumented 'generate_tokens' function public: https://github.com/python/cpython/pull/6957 I agree that it would be good to design a nicer API for this, but the perfect shouldn't be the en

[issue28418] Raise Deprecation warning for tokenize.generate_tokens

2018-05-17 Thread Thomas Kluyver
Thomas Kluyver added the comment: I've opened a PR moving in the other direction (making this public rather than deprecating it): https://github.com/python/cpython/pull/6957 -- nosy: +takluyver ___ Python tracker

[issue33562] Check that the global settings for asyncio are not changed by tests

2018-05-17 Thread Brett Cannon
New submission from Brett Cannon : There were not checks in test.libregrtest.save_env to make sure tests were not mucking with the default event loop. The settings to check seem to be: 'asyncio.get_event_loop_policy', 'asyncio.get_event_loop', 'asyncio_get_exception_handler', 'asyncio_get_debug

[issue33355] Windows 10 buildbot: 15 min timeout on test_mmap.test_large_filesize()

2018-05-17 Thread David Bolen
David Bolen added the comment: A longer timeout might be another workaround, but for myself, I tend to favor Zachary's original suggestion of eliminating largefile tests for the moment as simplest and most robust. It would also reduce the overall percentage of test time currently spent on a

[issue33562] Check that the global settings for asyncio are not changed by tests

2018-05-17 Thread Brett Cannon
Change by Brett Cannon : -- keywords: +patch pull_requests: +6617 stage: -> patch review ___ Python tracker ___ ___ Python-bugs-list

[issue32831] IDLE: Add docstrings and tests for codecontext

2018-05-17 Thread Terry J. Reedy
Terry J. Reedy added the comment: After this is merged, we should immediately add 'async' to the list of block openers. With complete tests, we can more confidently cleanup the code a bit, as well as change behavior. The fourth field of info tuples, block keyword, is never used as part of i

[issue33563] fileinput input's and Fileinput's bufsize=0 do not remit deprecationWarnings

2018-05-17 Thread Matthias Bussonnier
Change by Matthias Bussonnier : -- keywords: +patch pull_requests: +6618 stage: -> patch review ___ Python tracker ___ ___ Python-bu

[issue33563] fileinput input's and Fileinput's bufsize=0 do not remit deprecationWarnings

2018-05-17 Thread Matthias Bussonnier
New submission from Matthias Bussonnier : In Lib/fileinput.py, passing bufsize=0 does not raise any DeprecationWarning. Also when using `input` the stacklevel could be better as it passes bufsize directly for FileInput. in Lib/test/test_fileinput.py ; MockFileInput does not reflect the changes

[issue33459] Fix "tuple display" mention in Expressions

2018-05-17 Thread Andrés Delfino
Andrés Delfino added the comment: I'm restoring the original title since we are not sure it was incorrect after all. I have also updated the PR to remove the tuple display entry from the index. -- title: Define "tuple display" in the docs -> Fix "tuple display" mention in Expressions

[issue33355] Windows 10 buildbot: 15 min timeout on test_mmap.test_large_filesize()

2018-05-17 Thread Paul Goins
Paul Goins added the comment: I don't know enough about those tests and how important they are considered. My only concern would be with the increased risk of undetected breakage caused by removing them from CI, but if people think the risk is negligible and/or acceptable, it's fine by me.

[issue33564] IDLE: add 'async' to codecontext block openers

2018-05-17 Thread Terry J. Reedy
New submission from Terry J. Reedy : I am just going to add 'async' to BLOCKOPENERS. I don't think this needs a particular test, as most of the openers are not used in the new tests added by #32831. We could eventually expand the sample to have one of each opener. -- assignee: terry.

[issue32831] IDLE: Add docstrings and tests for codecontext

2018-05-17 Thread Terry J. Reedy
Terry J. Reedy added the comment: Because BLOCKOPENERS is sufficiently distant from the changes for this issue, I will add 'async' now, without tests, in #33564. Some of my comments for this issue are ideas for future changes in codecontext.py. -- ___

[issue33564] IDLE: add 'async' to codecontext block openers

2018-05-17 Thread Terry J. Reedy
Change by Terry J. Reedy : -- keywords: +patch pull_requests: +6619 stage: needs patch -> patch review ___ Python tracker ___ ___ Pyt

[issue33564] IDLE: add 'async' to codecontext block openers

2018-05-17 Thread Terry J. Reedy
Terry J. Reedy added the comment: New changeset d89ca94847d943b883ebcc68e4f0a18cb042ed0d by Terry Jan Reedy in branch 'master': bpo-33564: Add async to IDLE's code context block openers. (GH-6960) https://github.com/python/cpython/commit/d89ca94847d943b883ebcc68e4f0a18cb042ed0d -- _

[issue33564] IDLE: add 'async' to codecontext block openers

2018-05-17 Thread miss-islington
Change by miss-islington : -- pull_requests: +6620 ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe: https://mai

[issue33564] IDLE: add 'async' to codecontext block openers

2018-05-17 Thread miss-islington
Change by miss-islington : -- pull_requests: +6621 ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe: https://mai

[issue33554] Optimize PyDictObject

2018-05-17 Thread INADA Naoki
INADA Naoki added the comment: > A little performance optimization, but I think the key is not in performance optimization. > The semantics of the dictresize function are not uniform, and it is inconvenient for others to read. The dictresize function should be split to make it just resize. What

[issue33531] test_asyncio: test_subprocess test_stdin_broken_pipe() failure on Travis CI

2018-05-17 Thread Terry J. Reedy
Terry J. Reedy added the comment: I have also gotten test_async errors on AppVeyor and MSTS Windows. ERROR: test__sock_sendfile_native_failure (test.test_asyncio.test_base_events.BaseLoopSockSendfileTests) -- Traceback (most r

[issue33531] test_asyncio: test_subprocess test_stdin_broken_pipe() failure on Travis CI

2018-05-17 Thread Terry J. Reedy
Terry J. Reedy added the comment: I just got the two broken pipe error on Travis. -- ___ Python tracker ___ ___ Python-bugs-list mai

[issue31645] openssl build fails in win32 if .pl extension is not associated with Perl

2018-05-17 Thread Ivan Pozdeev
Change by Ivan Pozdeev : -- resolution: -> wont fix stage: -> resolved status: open -> closed ___ Python tracker ___ ___ Python-bug

[issue22552] ctypes.CDLL returns singleton objects, resulting in usage conflicts

2018-05-17 Thread Ivan Pozdeev
Change by Ivan Pozdeev : -- resolution: -> rejected stage: -> resolved status: open -> closed ___ Python tracker ___ ___ Python-bug

[issue28418] Raise Deprecation warning for tokenize.generate_tokens

2018-05-17 Thread Raymond Hettinger
Raymond Hettinger added the comment: Thanks Thomas. I've been a long term user of tokenize.generate_tokens() and would be sad to see it go. The underlying _tokenize() functionality is used else within the module, so there the no benefit to removing the API. -- nosy: +rhettinger _

[issue33564] IDLE: add 'async' to codecontext block openers

2018-05-17 Thread miss-islington
miss-islington added the comment: New changeset eb4590e4d9abecdbbc91c3531df83e1f9bed50f1 by Miss Islington (bot) in branch '3.6': bpo-33564: Add async to IDLE's code context block openers. (GH-6960) https://github.com/python/cpython/commit/eb4590e4d9abecdbbc91c3531df83e1f9bed50f1 --

[issue33531] test_asyncio: test_subprocess test_stdin_broken_pipe() failure on Travis CI

2018-05-17 Thread Terry J. Reedy
Terry J. Reedy added the comment: The Travis retest (for 3.7 backport) just failed with the same errors. Why can't we disable this tests. It now takes hours to do a merge with two backports. -- ___ Python tracker

[issue33547] Relative imports do not replace local variables

2018-05-17 Thread Rolf Campbell
Rolf Campbell added the comment: Thanks David, I agree that my assumption that the local valiables were not being replaced is not really what was going on there. I also agree that, while this might not strictly classify as a bug, it's probably not the most helpful/useful way that "from ." cou

[issue33564] IDLE: add 'async' to codecontext block openers

2018-05-17 Thread Terry J. Reedy
Terry J. Reedy added the comment: New changeset b2a02b9d88db04c12f800bc088afea0ef6862673 by Terry Jan Reedy (Miss Islington (bot)) in branch '3.7': bpo-33564: Add async to IDLE's code context block openers. (GH-6960) (#6961) https://github.com/python/cpython/commit/b2a02b9d88db04c12f800bc088af

[issue33556] leftover thread crumb in threading.ident docstring

2018-05-17 Thread Skip Montanaro
Change by Skip Montanaro : -- keywords: +patch pull_requests: +6622 stage: needs patch -> patch review ___ Python tracker ___ ___ Pyt

[issue33565] strange tracemalloc results

2018-05-17 Thread Alexander Mohr
Change by Alexander Mohr : -- type: -> behavior ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.

[issue33565] strange tracemalloc results

2018-05-17 Thread Alexander Mohr
New submission from Alexander Mohr : while investigating https://github.com/boto/botocore/issues/1464 I used tracemalloc (like I've done before in 3.5.2) to try to figure out where the leak was. To my surprise tracemalloc listed stacks that didn't make any sense. Strangest example is the top

[issue33564] IDLE: add 'async' to codecontext block openers

2018-05-17 Thread Terry J. Reedy
Change by Terry J. Reedy : -- resolution: -> fixed stage: patch review -> resolved status: open -> closed ___ Python tracker ___ ___

[issue33519] Should MutableSequence provide .copy()?

2018-05-17 Thread Jelle Zijlstra
Change by Jelle Zijlstra : -- keywords: +patch pull_requests: +6623 stage: -> patch review ___ Python tracker ___ ___ Python-bugs-li

[issue33522] Enable CI builds on Visual Studio Team Services

2018-05-17 Thread Gregory P. Smith
Gregory P. Smith added the comment: Your PRs made modifications to code and did not include a useful commit message or appropriate NEWS entries for the code modifications. Further, VSTS is unreliable. core-workflow made a premature decision to turn off Travis and AppVeyor and make VSTS block

[issue28556] typing.py upgrades

2018-05-17 Thread Ivan Levkivskyi
Change by Ivan Levkivskyi : -- pull_requests: +6624 ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe: https://ma

<    1   2