[issue29673] Some gdb macros are broken in 3.6

2018-04-06 Thread miss-islington
Change by miss-islington : -- pull_requests: +6106 ___ Python tracker ___

[issue33187] Document ElementInclude (XInclude) support in ElementTree

2018-04-06 Thread Ned Deily
Change by Ned Deily : -- keywords: +easy stage: -> needs patch versions: +Python 3.8 ___ Python tracker ___

[issue33227] Cmd do_something only accepts one argument

2018-04-06 Thread Oz Tiram
Oz Tiram added the comment: I am disappointed you want to deprecate CMD. I knew about cmd2 and some other alternatives, but I think their execive use of decorators isn't so comfortable. That is why I wrote my own module. I'm also willing to adopt the module and add even

[issue33238] AssertionError on await of Future returned by asyncio.wrap_future

2018-04-06 Thread Jason Haydaman
Jason Haydaman added the comment: May also be worth pointing out that even in the case of only calling set_result once, _done_callbacks still has _chain_future in it: import asyncio import concurrent.futures f = concurrent.futures.Future() async_f =

[issue33227] Cmd do_something only accepts one argument

2018-04-06 Thread Ned Deily
Ned Deily added the comment: The more I think about it, the more I feel it would be a disservice to our users to add piecemeal enhancements like this to the standard library cmd module at this point, when cmd is essentially unmaintained and there is already a superior

[issue29673] Some gdb macros are broken in 3.6

2018-04-06 Thread Ned Deily
Ned Deily added the comment: New changeset 3a9ccee0e5dbf7d67f5ab79f6095755969db117c by Ned Deily (Marcel Plch) in branch 'master': bpo-29673: fix gdb scripts pystack and pystackv (GH-6126) https://github.com/python/cpython/commit/3a9ccee0e5dbf7d67f5ab79f6095755969db117c

[issue29673] Some gdb macros are broken in 3.6

2018-04-06 Thread miss-islington
Change by miss-islington : -- pull_requests: +6105 ___ Python tracker ___

[issue33188] dataclass MRO entry resolution for type variable metaclasses: TypeError

2018-04-06 Thread Ivan Levkivskyi
Change by Ivan Levkivskyi : -- resolution: -> fixed stage: patch review -> resolved status: open -> closed ___ Python tracker ___

[issue29673] Some gdb macros are broken in 3.6

2018-04-06 Thread Ned Deily
Ned Deily added the comment: New changeset 3468a05f6a7d730a656d254730a3f5b6b7e85983 by Ned Deily (Miss Islington (bot)) in branch '3.6': [3.6] bpo-29673: fix gdb scripts pystack and pystackv (GH-6126) (GH-6400)

[issue29673] Some gdb macros are broken in 3.6

2018-04-06 Thread Ned Deily
Ned Deily added the comment: Thanks, Marcel, for the fix and thanks, Skip, for the review. Merged for release in 3.6.6 and 3.7.0. -- resolution: -> fixed stage: patch review -> resolved status: open -> closed ___ Python tracker

[issue33169] importlib.invalidate_caches() doesn't clear all caches

2018-04-06 Thread Brett Cannon
Change by Brett Cannon : -- pull_requests: +6108 ___ Python tracker ___ ___

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

2018-04-06 Thread Guido van Rossum
Guido van Rossum added the comment: But cmd is used by pdb. Do you recommend we deprecate that too? (There are countless 3rd party alternatives, but I sure prefer to have it in the stdlib, so I can start debugging without first having to install a dependency.) --

[issue8243] curses writing to window's bottom right position raises: `_curses.error: addstr() returned ERR'

2018-04-06 Thread Ned Deily
Ned Deily added the comment: New changeset ef5ce884a41c8553a7eff66ebace908c1dcc1f89 by Ned Deily (Jay Crotts) in branch 'master': bpo-8243: Doc patch for curses.window.addstr and curses.window.addch (GH-5179)

[issue33169] importlib.invalidate_caches() doesn't clear all caches

2018-04-06 Thread Brett Cannon
Brett Cannon added the comment: All done in 3.7 and master. -- resolution: -> fixed stage: patch review -> resolved status: open -> closed ___ Python tracker

[issue33169] importlib.invalidate_caches() doesn't clear all caches

2018-04-06 Thread Brett Cannon
Brett Cannon added the comment: New changeset a09bb87c1eebb07b01b8105cf536704893aec565 by Brett Cannon in branch '3.7': [3.7] bpo-33169: Remove values of `None` from sys.path_importer_cache when invalidating caches (GH-6402) (GH-6403)

[issue33211] lineno and col_offset are wrong on function definitions with decorators

2018-04-06 Thread Ivan Levkivskyi
Ivan Levkivskyi added the comment: > I was hoping to see if this was seen as a reasonable patch that might be > accepted. I didn't look carefully but superficially it looks reasonable, so it is worth trying. > Also, while I think it would be nice, I take it a patch for

[issue33185] Python 3.7.0b3 fails in pydoc where b2 did not.

2018-04-06 Thread Ned Deily
Change by Ned Deily : -- priority: critical -> release blocker stage: -> needs patch ___ Python tracker ___

[issue17861] put opcode information in one place

2018-04-06 Thread Ned Deily
Change by Ned Deily : -- resolution: -> fixed status: open -> closed ___ Python tracker ___

[issue8243] curses writing to window's bottom right position raises: `_curses.error: addstr() returned ERR'

2018-04-06 Thread Ned Deily
Ned Deily added the comment: New changeset 98e8ac8d82202aae32961f10b1014641ae1fffbf by Ned Deily (Miss Islington (bot)) in branch '3.7': [3.7] bpo-8243: Doc patch for curses.window.addstr and curses.window.addch (GH-5179) (GH-6404)

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

2018-04-06 Thread Guido van Rossum
Guido van Rossum added the comment: Well, is cmd2 stabilizing, or is it still changing at a rate too fast for inclusion in the stdlib? Does it perhaps have a mix of desirable and wacky features? Or could we just copy much of it into the stdlib as 'cmd'? I'm a bit concerned

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

2018-04-06 Thread Ned Deily
Ned Deily added the comment: > But I'm not ready to give up on the idea that Python comes with batteries > included. We should not let those batteries corrode and leak. I totally agree with you. And it would be great if cmd2 could be incorporated into the std lib as an

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

2018-04-06 Thread Ned Deily
Ned Deily added the comment: I've asked on python-dev for comments: https://mail.python.org/pipermail/python-dev/2018-April/152653.html -- ___ Python tracker

[issue33169] importlib.invalidate_caches() doesn't clear all caches

2018-04-06 Thread Brett Cannon
Change by Brett Cannon : -- keywords: +patch pull_requests: +6107 stage: -> patch review ___ Python tracker ___

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

2018-04-06 Thread Ned Deily
Ned Deily added the comment: @barry, I was thinking more of 3.8 but, sure, if there seems to be a consensus prior to 3.7.0b4 that deprecation is the right thing, we could do it in 3.7. -- ___ Python tracker

[issue33169] importlib.invalidate_caches() doesn't clear all caches

2018-04-06 Thread Brett Cannon
Brett Cannon added the comment: New changeset 9e2be60634914f23db2ae5624e4acc9335bf5fea by Brett Cannon in branch 'master': bpo-33169: Remove values of `None` from sys.path_importer_cache when invalidating caches (GH-6402)

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

2018-04-06 Thread Steven D'Aprano
Steven D'Aprano added the comment: (Previously posted on Python-Dev.) I think the documentation note is a good idea. But I disagree with deprecating "cmd" unless it is actively falling apart and no longer working, not just languishing with no feature improvements.

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

2018-04-06 Thread Raymond Hettinger
Raymond Hettinger added the comment: FWIW, I've been teaching cmd to my clients for years and it has worked fine for them. -- nosy: +rhettinger ___ Python tracker

[issue8243] curses writing to window's bottom right position raises: `_curses.error: addstr() returned ERR'

2018-04-06 Thread Ned Deily
Ned Deily added the comment: New changeset 77f0a41d72886513f5e9277e5587455745c29ac1 by Ned Deily (Miss Islington (bot)) in branch '2.7': [2.7] bpo-8243: Doc patch for curses.window.addstr and curses.window.addch (GH-5179) (GH-6405)

[issue8243] curses writing to window's bottom right position raises: `_curses.error: addstr() returned ERR'

2018-04-06 Thread Ned Deily
Ned Deily added the comment: New changeset 70c44465475c41ab3aa832858b250ede6f170aac by Ned Deily (Miss Islington (bot)) in branch '3.6': [3.6] bpo-8243: Doc patch for curses.window.addstr and curses.window.addch (GH-5179) (GH-6406)

[issue8243] curses writing to window's bottom right position raises: `_curses.error: addstr() returned ERR'

2018-04-06 Thread Ned Deily
Ned Deily added the comment: Thank you for producing the PR, Jay! -- components: -Extension Modules resolution: -> fixed stage: patch review -> resolved status: open -> closed type: enhancement -> versions: +Python 2.7, Python 3.6, Python 3.7

[issue33227] Cmd do_something only accepts one argument

2018-04-06 Thread Ned Deily
Ned Deily added the comment: Oz, I don't particularly like the idea of deprecating cmd but, realistically, Python development is almost entirely an unpaid, volunteer activity and we do not have enough resources to do everything we'd like to do. So sometimes we need to make

[issue13940] imaplib: Mailbox names are not quoted

2018-04-06 Thread Mark Lawrence
Change by Mark Lawrence : -- nosy: -BreamoreBoy ___ Python tracker ___ ___

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

2018-04-06 Thread Barry A. Warsaw
Barry A. Warsaw added the comment: @ned.deily - are you proposing to officially deprecate it for 3.7? If we're going to do it, let's do it now so we can remove it for 3.9. It seems like a reasonable strategy to push folks toward cmd2 and clean up our stdlib. --

[issue33053] Avoid adding an empty directory to sys.path when running a module with `-m`

2018-04-06 Thread Ned Deily
Ned Deily added the comment: (See Issue33185 for regression.) -- ___ Python tracker ___

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

2018-04-06 Thread Guido van Rossum
Guido van Rossum added the comment: I'm fine with linking to cmd2, we do that for some other modules too. (Though I think it's somewhat arbitrary. E.g. do we link to requests anywhere? Or to all the "better pdb" modules?) -- ___

[issue29673] Some gdb macros are broken in 3.6

2018-04-06 Thread Ned Deily
Ned Deily added the comment: New changeset 3c193cf8afce525b1283986f113de0e16f23e115 by Ned Deily (Miss Islington (bot)) in branch '3.7': [3.7] bpo-29673: fix gdb scripts pystack and pystackv (GH-6126) (GH-6399)

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

2018-04-06 Thread Ned Deily
Ned Deily added the comment: > cmd is used by pdb Well, that's a pretty good reason for not removing cmd! I really wasn't advocating its removal, just gently pushing users to use cmd2. So perhaps we should only add a "See Also" like we do for urllib.request and close any

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

2018-04-06 Thread Ned Deily
Ned Deily added the comment: > FWIW, I've been teaching cmd to my clients for years and it has worked fine > for them. I'm not saying that cmd is bad; it's just that there have been suggested improvements over the years and many of those are already implemented in cmd2,

[issue8243] curses writing to window's bottom right position raises: `_curses.error: addstr() returned ERR'

2018-04-06 Thread miss-islington
Change by miss-islington : -- pull_requests: +6110 ___ Python tracker ___

[issue8243] curses writing to window's bottom right position raises: `_curses.error: addstr() returned ERR'

2018-04-06 Thread miss-islington
Change by miss-islington : -- pull_requests: +6109 ___ Python tracker ___

[issue8243] curses writing to window's bottom right position raises: `_curses.error: addstr() returned ERR'

2018-04-06 Thread miss-islington
Change by miss-islington : -- pull_requests: +6111 ___ Python tracker ___

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

2018-04-06 Thread Ned Deily
Ned Deily added the comment: > (Though I think it's somewhat arbitrary. Yes, it is. > E.g. do we link to requests anywhere? Yes: https://docs.python.org/3/library/urllib.request.html > Or to all the "better pdb" modules?) Not that I'm aware of. --

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

2018-04-06 Thread Catherine Devlin
Catherine Devlin added the comment: Hi, everybody! I really appreciate the kind words about cmd2. For several years now, Todd Leonhardt has been cmd2's primary maintainer, so I may be speaking out of turn. But, before I wanted to let it get within

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

2018-04-06 Thread Raymond Hettinger
Raymond Hettinger added the comment: > cmd seems to be largely abandoned in the std lib: I'm not sure why the absence of bugs indicates abandonment. We almost never touch defaultdict, in part because the code is straight-forward, tested, and not buggy. If a

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

2018-04-06 Thread Todd Leonhardt
Todd Leonhardt added the comment: The cmd2 project is in the process of rapidly stabilizing, but it isn't quite there yet. The other cmd2 core maintainers and I do have a bunch of refactoring planned over the next 6 to 8 months or so. Right now @kotfu (Jared Crapo)

[issue33231] Potential memory leak in normalizestring()

2018-04-06 Thread INADA Naoki
INADA Naoki added the comment: > Only reason I can see to avoid this would be if the codec names could contain > arbitrary Unicode encoded as UTF-8 (and therefore strlen wouldn't tell you > the final length in Unicode ordinals), but I'm pretty sure that's not the >

[issue33231] Potential memory leak in normalizestring()

2018-04-06 Thread miss-islington
Change by miss-islington : -- pull_requests: +6102 ___ Python tracker ___

[issue33231] Potential memory leak in normalizestring()

2018-04-06 Thread miss-islington
miss-islington added the comment: New changeset 64421d9237e33725e3c2916cdf2b6d6da1751c2a by Miss Islington (bot) in branch '3.7': bpo-33231: Fix potential leak in normalizestring() (GH-6386)

[issue33236] MagicMock().__iter__.return_value is different from MagicMock().__iter__()

2018-04-06 Thread Robert
New submission from Robert : According to the documentation .return_value should be identical to the object returned when calling the mock ("assert m() is m.return_value") This is the case except on objects returned by __iter__ on MagicMocks. The following script demonstrates

[issue33231] Potential memory leak in normalizestring()

2018-04-06 Thread INADA Naoki
Change by INADA Naoki : -- stage: patch review -> resolved status: open -> closed ___ Python tracker ___

[issue5305] imaplib should support international mailbox names

2018-04-06 Thread Alexander Harkness
Alexander Harkness added the comment: ssu -- nosy: +bearbin ___ Python tracker ___ ___

[issue13940] imaplib: Mailbox names are not quoted

2018-04-06 Thread Alexander Harkness
Change by Alexander Harkness : -- nosy: +bearbin ___ Python tracker ___ ___

[issue33235] Better help text for dict.setdefault

2018-04-06 Thread Paddy McCarthy
New submission from Paddy McCarthy : Hi, I was answering some question and used dict.setdefault as part of the solution and posted the help() on it as part of my answer. The help was this: In [15]: help(mapper.setdefault) Help on built-in function setdefault:

[issue13940] imaplib: Mailbox names are not quoted

2018-04-06 Thread Alexander Harkness
Change by Alexander Harkness : -- pull_requests: +6103 stage: -> patch review ___ Python tracker ___

[issue33231] Potential memory leak in normalizestring()

2018-04-06 Thread INADA Naoki
INADA Naoki added the comment: New changeset 0c1c4563a65ac451021d927058e4f25013934eb2 by INADA Naoki in branch 'master': bpo-33231: Fix potential leak in normalizestring() (GH-6386) https://github.com/python/cpython/commit/0c1c4563a65ac451021d927058e4f25013934eb2

[issue33231] Potential memory leak in normalizestring()

2018-04-06 Thread miss-islington
Change by miss-islington : -- pull_requests: +6101 ___ Python tracker ___

[issue33231] Potential memory leak in normalizestring()

2018-04-06 Thread miss-islington
miss-islington added the comment: New changeset 2350a4765265158072bf7ad9f04402406d3d1ada by Miss Islington (bot) in branch '3.6': bpo-33231: Fix potential leak in normalizestring() (GH-6386)

[issue33231] Potential memory leak in normalizestring()

2018-04-06 Thread INADA Naoki
Change by INADA Naoki : -- resolution: -> fixed ___ Python tracker ___ ___

[issue33237] Improve AttributeError message for partially initialized module

2018-04-06 Thread Serhiy Storchaka
Change by Serhiy Storchaka : -- keywords: +patch pull_requests: +6104 stage: -> patch review ___ Python tracker ___

[issue33210] pkgutil.walk_packages gives incomplete results

2018-04-06 Thread Nick Coghlan
Nick Coghlan added the comment: I think this is actually two distinct problems, one documentation one (which should be addressed in the online docs for all currently maintained versions), and one actual functional issue. The documentation issue is the one you've reported:

[issue33237] Improve AttributeError message for partially initialized module

2018-04-06 Thread Serhiy Storchaka
New submission from Serhiy Storchaka : Cyclic import usually leads to an AttributeError "module 'spam' has no attribute 'ham'" which usually is confusing because in normal case 'spam.ham' exists, and the user can have no ideas why it is disappeared. The proposed

[issue33210] pkgutil.walk_packages "prefix" option docs are misleading

2018-04-06 Thread Nick Coghlan
Nick Coghlan added the comment: https://bugs.python.org/issue29258 is an existing issue for the PEP 420 limitation (it also notes why fixing that implicitly is a potential problem) I've retitled this issue to be specifically about the misleading docs for the "prefix"

[issue32933] mock_open does not support iteration around text files.

2018-04-06 Thread Éric Araujo
Éric Araujo added the comment: Is this related to #33236 ? -- nosy: +eric.araujo ___ Python tracker ___

[issue32933] mock_open does not support iteration around text files.

2018-04-06 Thread Anthony Flury
Anthony Flury added the comment: No - it isn't related. In the case of mock_open; it isn't intended to be a simple MagicMock - it is meant to be a mocked version of open, and so to be useful as a testing tool, it should emulate a file as much as possible.

[issue33214] join method for list and tuple

2018-04-06 Thread Éric Araujo
Change by Éric Araujo : -- nosy: +eric.araujo ___ Python tracker ___ ___ Python-bugs-list

[issue33235] Better help text for dict.setdefault

2018-04-06 Thread Éric Araujo
Éric Araujo added the comment: Note that if we switch the order like you propose, we don’t need to use dict.get: set D[k]=d if k not in D then return D[k] I suspect the current doc was written the way it is because it matches the actual implementation. --

[issue33235] Better help text for dict.setdefault

2018-04-06 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: Changing docstring can break existing code, therefore it should go only in future new Python version unless it contains a bug. The current docstring in 3.6 doesn't look incorrect to me. The docstring in 3.7 is different.

[issue33237] Improve AttributeError message for partially initialized module

2018-04-06 Thread Nick Coghlan
Nick Coghlan added the comment: While I like the idea of this change, the "partially initialized" addition is fairly subtle, and relatively easy to miss. Perhaps append "(most likely due to a circular import)" to the partially initialized case?: AttributeError:

[issue33189] pygettext doesn't work with f-strings

2018-04-06 Thread Éric Araujo
Change by Éric Araujo : -- nosy: +eric.araujo ___ Python tracker ___ ___ Python-bugs-list

[issue33235] Better help text for dict.setdefault

2018-04-06 Thread Éric Araujo
Éric Araujo added the comment: The two lines are equivalent! `d.setdefault(key, default)` does return the same thing as `d.get(key, default)`, and then sets `d[key] = default` if the get method went into the “key was not found, let’s return default” branch. --

[issue33227] Cmd do_something only accepts one argument

2018-04-06 Thread Éric Araujo
Éric Araujo added the comment: I think using shlex unconditionally to parse lines sent to cmd.Cmd may not be ideal. Cmd is very generic and there are many ways to parse lines into arguments: - no parsing (think Python shells or remote command execution) - shlex (makes sense

[issue33230] _decimal build failure (unsupported platform for that module) - evolution possible?

2018-04-06 Thread Hubert Holin
Hubert Holin added the comment: This is correct: I had an older version of mpdecimal in /usr/local. However, when removed mpdecimal is (manually) removed from /usr/local (the libs and the header), making a "make clean", a config and make, the _decimal build still fails,

[issue33230] _decimal build failure (unsupported platform for that module) - evolution possible?

2018-04-06 Thread Stefan Krah
Stefan Krah added the comment: It looks to me as if you are compiling --with-system-libmpdec. You don't need that, libmpdec is included in the Python tarball. -with-system-libmpdec was added mainly for Linux distros. If there's a widespread interest to support it on OS

[issue33230] _decimal build failure (unsupported platform for that module) - evolution possible?

2018-04-06 Thread Stefan Krah
Stefan Krah added the comment: Another source of error is of course if the external libmpdec was not compiled as "universal" but Python is. -- ___ Python tracker

[issue33238] AssertionError on await of Future returned by asyncio.wrap_future

2018-04-06 Thread Jason Haydaman
New submission from Jason Haydaman : When the concurrent Future wrapped by asyncio.wrap_future has set_result or set_exception called multiple times, I get the following traceback: Traceback (most recent call last): File