-
-
Notifications
You must be signed in to change notification settings - Fork 31.4k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
bpo-30978: str.format_map() now passes key lookup exceptions through. #2790
bpo-30978: str.format_map() now passes key lookup exceptions through. #2790
Conversation
@serhiy-storchaka, thanks for your PR! By analyzing the history of the files in this pull request, we identified @ericvsmith, @pitrou and @doerwalter to be potential reviewers. |
A test fails:ERROR: test_match_getitem (test.test_re.ReTests) Traceback (most recent call last): File "/home/travis/build/python/cpython/Lib/test/test_re.py", line 472, in test_match_getitem
IndexError: no such group You should document this behaviour change in the NEWS entry (and fix the test). |
Other than the failing test in test_re, this looks good to me. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks, it's now better with NEWS describing the old behaviour ;-)
@@ -1 +1,2 @@ | |||
str.format_map() now passes key lookup exceptions through. | |||
Previousle any exception was replaced with a KeyError exception. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Typo: Previousle -> Previously
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks!
…rough. (pythonGH-2790) Previously any exception was replaced with a KeyError exception. (cherry picked from commit 5075416)
GH-2992 is a backport of this pull request to the 3.6 branch. |
No description provided.