GH-101578: Normalize the current exception by markshannon · Pull Request #101607 · python/cpython · GitHub

github.com

Tin mới

faster-cpython:normalize-current-exception

GitHub CopilotWrite better code with AI

GitHub Copilot appDirect agents from issue to merge

ActionsAutomate any workflow

CodespacesInstant dev environments

IssuesPlan and track work

Code ReviewManage code changes

Code QualityEnforce quality at merge

GitHub Advanced SecurityFind and fix vulnerabilities

Code securitySecure your code as you build

Secret protectionStop leaks before they start

View all use cases

Financial services

View all industries

Software Development

GitHub SponsorsFund open source developers

Copilot for BusinessEnterprise-grade AI features

Premium SupportEnterprise-grade 24/7 support

Pull requests 2.6k

Security and quality 0

PyErr_SetObject() behavior is strange and not as documented. #101578

Make sure that the current exception is always normalized.

Remove redundant type and traceback fields for the current exception.

Replace a some uses of PyErr_Fetch with PyErr_Fetch1.

Refactor assertion.

Document new C-API functions

awaiting core review

awaiting core review

View reviewed changes

Learn more about hiding disruptive comments

The reason will be displayed to describe this comment to others. Learn more.

Update generated code.

Rename new functions and fix up docs.

Update stable ABI.

View reviewed changes

Restore behavior of PyErr_Restore, and add tests.

View reviewed changes

🔨 test-with-buildbots

🔨 test-with-buildbots

Merge branch 'main' into inlinecomp2

gh-101578: Amend PyErr_{Set,Get}RaisedException docs #101962

gh-101578: Amend exception docs #102057

[BUG] Fast thread state access is broken by Py3.12a6 cython/cython#5286

gh-101607 causes regression in third-party psutil package on macOS #102493

Suspected PyErr_Fetch() behavior change #102594

sys.exit unpacks its argument if it is a 0- or 1-element tuple #133548