-
-
Notifications
You must be signed in to change notification settings - Fork 31.8k
bpo-45613: Set sqlite3.threadsafety
dynamically
#29227
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
Use the compile-time selected default SQLite threaded mode to set the DB-API 2.0 attribute 'threadsafety' Mappings: - SQLITE_THREADSAFE=0 => threadsafety=0 - SQLITE_THREADSAFE=1 => threadsafety=3 - SQLITE_THREADSAFE=2 => threadsafety=1
|
🤖 New build scheduled with the buildbot fleet by @erlend-aasland for commit 396abd4 🤖 If you want to schedule another build, you need to add the ":hammer: test-with-buildbots" label again. |
Testing with buildbots to verify that this approach works across different SQLite versions/configurations. I've verified locally that it works with SQLite 3.7.15 (oldest supported), 3.36.0, and current 3.37.0 (dev). |
🤖 New build scheduled with the buildbot fleet by @erlend-aasland for commit 686d70f 🤖 If you want to schedule another build, you need to add the ":hammer: test-with-buildbots" label again. |
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.
I think the patch is good to go as-is, without the additional changes you mentioned in the comments. Thanks, Erlend.
Thanks! There is one change I'd like to make before merging, though: add a |
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.
LGTM
@malemburg do you have anything else you would like here to be addressed?
Edit: ah, I just saw that you approved before. I am landing this then
Thanks, Marc-Andre & Pablo 🙏🏻 |
Use the compile-time selected default SQLite threaded mode to set the
DB-API 2.0 attribute 'threadsafety' during sqlite3 module initialisation.
SQLite to DB-API mappings:
https://bugs.python.org/issue45613