Uh oh!
There was an error while loading.Please reload this page.
- Notifications
You must be signed in to change notification settings - Fork33.7k
gh-126018: Avoid aborting due to unnecessary assert insys.audit#126020
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 ourterms of service andprivacy statement. We’ll occasionally send you account related emails.
Already on GitHub?Sign in to your account
Uh oh!
There was an error while loading.Please reload this page.
Conversation
picnixz commentedOct 26, 2024
This likely requires some NEWS entry, for instance: Fix a crash in:func:`sys.audit` when passing a non-string argument. |
Uh oh!
There was an error while loading.Please reload this page.
Uh oh!
There was an error while loading.Please reload this page.
Uh oh!
There was an error while loading.Please reload this page.
picnixz commentedOct 26, 2024
FTR: 3.12 is not affected because the assertion does not exist: Lines 499 to 514 in67b2701
|
Co-authored-by: Bénédikt Tran <10796600+picnixz@users.noreply.github.com>
devdanzin commentedOct 27, 2024
Uh oh!
There was an error while loading.Please reload this page.
Misc/NEWS.d/next/Core_and_Builtins/2024-10-26-23-50-03.gh-issue-126018.Hq-qcM.rst OutdatedShow resolvedHide resolved
Uh oh!
There was an error while loading.Please reload this page.
ZeroIntensity left a comment
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.
This works, but I would be more comfortable just converting this to clinic.
Co-authored-by: Jelle Zijlstra <jelle.zijlstra@gmail.com>
devdanzin commentedOct 27, 2024
I'm not too attached to this PR, but converting to AC is beyond my skills. If you or someone else wants to propose another PR with that approach, I'll gladly close this one. |
JelleZijlstra commentedOct 27, 2024
Converting to AC can wait for a later PR, and probably should be done only in main. |
80eec52 intopython:mainUh oh!
There was an error while loading.Please reload this page.
Thanks@devdanzin for the PR, and@JelleZijlstra for merging it 🌮🎉.. I'm working now to backport this PR to: 3.13. |
…it` (pythonGH-126020)(cherry picked from commit80eec52)Co-authored-by: devdanzin <74280297+devdanzin@users.noreply.github.com>Co-authored-by: Bénédikt Tran <10796600+picnixz@users.noreply.github.com>Co-authored-by: Jelle Zijlstra <jelle.zijlstra@gmail.com>
GH-126042 is a backport of this pull request to the3.13 branch. |
…it` (python#126020)Co-authored-by: Bénédikt Tran <10796600+picnixz@users.noreply.github.com>Co-authored-by: Jelle Zijlstra <jelle.zijlstra@gmail.com>
…it` (python#126020)Co-authored-by: Bénédikt Tran <10796600+picnixz@users.noreply.github.com>Co-authored-by: Jelle Zijlstra <jelle.zijlstra@gmail.com>
Uh oh!
There was an error while loading.Please reload this page.
This PR removes an assert in
sysmodule.cthat caused the interpreter to abort whensys.auditreceived a non-string as first argument.Without this assert, the code that runs the hooks will raise an exception instead.
sys.audit(0)aborts due to an assertion in debug build #126018