
This issue trackerhas been migrated toGitHub, and is currentlyread-only.
For more information, see the GitHub FAQs in the Python's Developer Guide.
Created on2017-07-28 16:03 byStefan Pochmann, last changed2022-04-11 14:58 byadmin. This issue is nowclosed.
| Pull Requests | |||
|---|---|---|---|
| URL | Status | Linked | Edit |
| PR 2957 | merged | serhiy.storchaka,2017-07-31 10:31 | |
| PR 2991 | merged | serhiy.storchaka,2017-08-03 08:40 | |
| Messages (4) | |||
|---|---|---|---|
| msg299402 -(view) | Author: Stefan Pochmann (Stefan Pochmann)* | Date: 2017-07-28 16:03 | |
Python 3.6 makes it sound like maps aren't iterable:>>> map(str, *map(int, [[]]))Traceback (most recent call last): File "<pyshell#0>", line 1, in <module> map(str, *map(int, [[]]))TypeError: type object argument after * must be an iterable, not mapMore, including a likely explanation, in my question and its answer here:https://stackoverflow.com/q/45363330/1672429Apparently the TypeError from int([]) gets mistaken for a TypeError indicating non-iterability of the map object. | |||
| msg299411 -(view) | Author: R. David Murray (r.david.murray)*![]() | Date: 2017-07-28 17:07 | |
Thanks for the report. Retitling because this has nothing to do with map:>>> def foo(*args):... raise TypeError('fake')... yield 1... >>> foo(1, *foo())Traceback (most recent call last): File "<stdin>", line 1, in <module>TypeError: foo() argument after * must be an iterable, not generator>>> foo(*foo())Traceback (most recent call last): File "<stdin>", line 1, in <module> File "<stdin>", line 2, in fooTypeError: fake | |||
| msg299690 -(view) | Author: Serhiy Storchaka (serhiy.storchaka)*![]() | Date: 2017-08-03 08:37 | |
New changeset25e4f779d7ae9f37a1933cb5cbfad06e673c01f9 by Serhiy Storchaka in branch 'master':bpo-31071: Avoid masking original TypeError in call with * unpacking (#2957)https://github.com/python/cpython/commit/25e4f779d7ae9f37a1933cb5cbfad06e673c01f9 | |||
| msg299694 -(view) | Author: Serhiy Storchaka (serhiy.storchaka)*![]() | Date: 2017-08-03 09:14 | |
New changeset946a0b69e217ff22a6c056047eab42053e9a2d5f by Serhiy Storchaka in branch '3.6':[3.6]bpo-31071: Avoid masking original TypeError in call with * unpacking (GH-2957) (#2991)https://github.com/python/cpython/commit/946a0b69e217ff22a6c056047eab42053e9a2d5f | |||
| History | |||
|---|---|---|---|
| Date | User | Action | Args |
| 2022-04-11 14:58:49 | admin | set | github: 75254 |
| 2017-08-03 09:18:25 | serhiy.storchaka | set | status: open -> closed resolution: fixed stage: patch review -> resolved |
| 2017-08-03 09:14:37 | serhiy.storchaka | set | messages: +msg299694 |
| 2017-08-03 08:40:10 | serhiy.storchaka | set | pull_requests: +pull_request3030 |
| 2017-08-03 08:37:19 | serhiy.storchaka | set | messages: +msg299690 |
| 2017-07-31 10:32:38 | serhiy.storchaka | set | assignee:serhiy.storchaka nosy: +serhiy.storchaka components: + Interpreter Core stage: needs patch -> patch review |
| 2017-07-31 10:31:51 | serhiy.storchaka | set | pull_requests: +pull_request3005 |
| 2017-07-28 17:07:53 | r.david.murray | set | nosy: +r.david.murray title: Bad error message about maps not iterable -> *args unpacking can mask TypeErrors messages: +msg299411 versions: + Python 3.7 stage: needs patch |
| 2017-07-28 16:03:22 | Stefan Pochmann | create | |