Skip to content

Close raw sqlite connections in MCP tests - #5

Merged
jdbadger merged 1 commit into
mainfrom
address-sqlite-conn-warning
Sep 19, 2026
Merged

jdbadger merged 1 commit into
mainfrom
address-sqlite-conn-warning

Conversation

@jdbadger

Copy link
Copy Markdown
Owner

sqlite3.Connection's context manager commits or rolls back but never closes, so three tests leaked a connection each. Garbage collection closed them later, and Python 3.13 reported a ResourceWarning against whichever test happened to be running then. Wrap them in contextlib.closing.

sqlite3.Connection's context manager commits or rolls back but never
closes, so three tests leaked a connection each. Garbage collection closed
them later, and Python 3.13 reported a ResourceWarning against whichever
test happened to be running then. Wrap them in contextlib.closing.
@jdbadger jdbadger self-assigned this Sep 19, 2026
@jdbadger
jdbadger merged commit 4c102ab into main Sep 19, 2026
5 checks passed
@jdbadger
jdbadger deleted the address-sqlite-conn-warning branch September 19, 2026 12:58
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.

1 participant