Erlend E. Aasland <erlend.aasl...@innova.no> added the comment:
> In fact the exception is in the `pass` line rather than in the `execute` line. I can reproduce this without the `pass` line. I've taken the liberty to create a PR based on your patch, Luca. Berker's comments have been addressed in the PR. ---------- title: pysqlite3 context manager not performing rollback when a database is locked elsewhere for non-DML statements -> [sqlite3] context manager leaves db locked if commit fails in __exit__ versions: +Python 3.10, Python 3.11, Python 3.9 -Python 3.5, Python 3.6 _______________________________________ Python tracker <rep...@bugs.python.org> <https://bugs.python.org/issue27334> _______________________________________ _______________________________________________ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com