-
-
Notifications
You must be signed in to change notification settings - Fork 32.1k
bpo-37347: fix refcount problem in sqlite3 #14268
8000 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
Conversation
7a61d42
to
6d75038
Compare
Lib/sqlite3/test/regression.py
Outdated
log = printer_instance.log | ||
refcnt_before = sys.getrefcount(log) | ||
method(log) | ||
refcnt_after = sys.getrefcount(log) |
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.
We should try to avoid writing tests that use sys.getrefcount
. Does this test fail if you pass -R ::
to regrtest.py
?
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.
Nope. But it can be rewritten to fall to segmentation fault.
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.
Sounds good to me. Not crashing is the behavior we want to test anyway.
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.
Then it is done in d1b57ff.
Thanks @gescheit for the PR, and @benjaminp for merging it 🌮🎉.. I'm working now to backport this PR to: 3.8. |
GH-14725 is a backport of this pull request to the 3.8 branch. |
(cherry picked from commit b9a0376) Co-authored-by: gescheit <gescheit@yandex-team.ru>
fix refcount problem in sqlite3
https://bugs.python.org/issue37347