Skip to content

SQLite: fix transaction level accounting with bad custom command.#3981

Merged
abonander merged 1 commit intolaunchbadge:mainfrom
kevincox:sqlite-custom-command
Aug 18, 2025
Merged

SQLite: fix transaction level accounting with bad custom command.#3981
abonander merged 1 commit intolaunchbadge:mainfrom
kevincox:sqlite-custom-command

Conversation

@kevincox
Copy link
Contributor

In the previous code the worker would always assume that the custom command worked. However the higher level code would run a check and notice that a transaction was not actually started and raise an error without rolling back the transaction.

This improves the code by moving the transaction check into the worker to ensure that the transaction depth tracker is only modified if the user's custom command actually started a transaction.

Fixes: #3932

Is this a breaking change?

No.

In the previous code the worker would always assume that the custom command worked. However the higher level code would run a check and notice that a transaction was not actually started and raise an error without rolling back the transaction.

This improves the code by moving the transaction check into the worker to ensure that the transaction depth tracker is only modified if the user's custom command actually started a transaction.

Fixes: launchbadge#3932
@abonander abonander changed the title Fix transaction level accounting with bad custom command. SQLite: fix transaction level accounting with bad custom command. Aug 18, 2025
@abonander abonander merged commit 1f7af3a into launchbadge:main Aug 18, 2025
92 checks passed
@kevincox kevincox deleted the sqlite-custom-command branch August 18, 2025 23:20
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

sqlite transaction creation is not error or drop-safe.

2 participants