Skip to content
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-38631: Avoid Py_FatalError() in PyModule_Create2() #18212

Merged
merged 1 commit into from Jan 27, 2020

Conversation

@vstinner
Copy link
Member

vstinner commented Jan 27, 2020

If PyModule_Create2() is called when the Python import machinery is
not initialized, it now raises a SystemError and returns NULL,
instead of calling Py_FatalError() which aborts the process.

The caller must be prepared to handle NULL anyway.

https://bugs.python.org/issue38631

If PyModule_Create2() is called when the Python import machinery is
not initialized, it now raises a SystemError and returns NULL,
instead of calling Py_FatalError() which aborts the process.

The caller must be prepared to handle NULL anyway.
@vstinner vstinner force-pushed the vstinner:pymodule_create2 branch from d743130 to e9992bd Jan 27, 2020
@vstinner vstinner merged commit a94c6b6 into python:master Jan 27, 2020
8 checks passed
8 checks passed
Windows (x86)
Details
Windows (x64)
Details
macOS
Details
Ubuntu
Details
Azure Pipelines PR #20200127.45 succeeded
Details
bedevere/issue-number Issue number 38631 found
Details
bedevere/news "skip news" label found
continuous-integration/travis-ci/pr The Travis CI build passed
Details
@vstinner vstinner deleted the vstinner:pymodule_create2 branch Jan 27, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
3 participants
You can’t perform that action at this time.