-
-
Notifications
You must be signed in to change notification settings - Fork 34.5k
gh-95913: Fix and copyedit New Features section of 3.11 What's New #95915
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
Merged
encukou
merged 5 commits into
python:main
from
CAM-Gerlach:whatsnew-copyedit-new-features
Sep 19, 2022
Merged
Changes from 1 commit
Commits
Show all changes
5 commits
Select commit
Hold shift + click to select a range
d0e8c28
3.11 Whatsnew: Revise desc of enhanced error locations feature
CAM-Gerlach 7dacbbf
3.11 Whatsnew: Combine error locations sections to avoid duplication
CAM-Gerlach 548e6c7
3.11 Whatsnew: Copyedit section describing exception notes
CAM-Gerlach 81add60
gh-95914: Add to What's New a credit for PEP 678 author
iritkatriel 3c4a03a
Add standardized ref links to sections
CAM-Gerlach File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3.11 Whatsnew: Combine error locations sections to avoid duplication
- Loading branch information
commit 7dacbbfea7a699eb243e5cbde96878f55f795704
There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change | ||||
|---|---|---|---|---|---|---|
|
|
@@ -149,6 +149,14 @@ As well as complex arithmetic expressions: | |||||
| ~~~~~~^~~ | ||||||
| ZeroDivisionError: division by zero | ||||||
|
|
||||||
| Additionally, the information used by the enhanced traceback feature | ||||||
| is made available via a general API, that can be used to correlate | ||||||
| :term:`bytecode` :ref:`instructions <bytecodes>` with source code location. | ||||||
| This information can be retrieved using: | ||||||
|
|
||||||
| - The :meth:`codeobject.co_positions` method in Python. | ||||||
| - The :c:func:`PyCode_Addr2Location` function in the C API. | ||||||
|
|
||||||
| See :pep:`657` for more details. (Contributed by Pablo Galindo, Batuhan Taskaya | ||||||
| and Ammar Askar in :issue:`43950`.) | ||||||
|
Member
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more.
Suggested change
Member
Author
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. See above |
||||||
|
|
||||||
|
|
@@ -162,23 +170,6 @@ and Ammar Askar in :issue:`43950`.) | |||||
| or the :envvar:`PYTHONNODEBUGRANGES` environment variable. | ||||||
|
|
||||||
|
|
||||||
| Column information for code objects | ||||||
| ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ | ||||||
|
|
||||||
| The information used by the enhanced traceback feature is made available as a | ||||||
| general API that can be used to correlate bytecode instructions with source | ||||||
| code. This information can be retrieved using: | ||||||
|
|
||||||
| - The :meth:`codeobject.co_positions` method in Python. | ||||||
| - The :c:func:`PyCode_Addr2Location` function in the C-API. | ||||||
|
|
||||||
| The :option:`-X` ``no_debug_ranges`` option and the environment variable | ||||||
| :envvar:`PYTHONNODEBUGRANGES` can be used to disable this feature. | ||||||
|
|
||||||
| See :pep:`657` for more details. (Contributed by Pablo Galindo, Batuhan Taskaya | ||||||
| and Ammar Askar in :issue:`43950`.) | ||||||
|
|
||||||
|
|
||||||
| PEP 654: Exception Groups and ``except*`` | ||||||
| ----------------------------------------- | ||||||
|
|
||||||
|
|
||||||
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
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.
How does this change affect
:ref:and index entries linking (if it does)?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.
It doesn't affect the index entries (it still links to the same place, right above the section) but fixes an issue with the ref target not actually being the section as intended, and thus not having a generated link text causing
:ref:`codeobjects`to error out. It won't affect any existing refs, since it only changes the generated link text and not the ref target location, which the existing refs could not be using or they would have errored and failed the build.