Skip to content

Make schema hash resilient to SQLite maintenance operations#320

Merged
goodmami merged 1 commit into
goodmami:mainfrom
pajusmar:schema-compatibility
Mar 18, 2026
Merged

Make schema hash resilient to SQLite maintenance operations#320
goodmami merged 1 commit into
goodmami:mainfrom
pajusmar:schema-compatibility

Conversation

@pajusmar

@pajusmar pajusmar commented Mar 1, 2026

Copy link
Copy Markdown
Contributor

Fix #319

@pajusmar

pajusmar commented Mar 1, 2026

Copy link
Copy Markdown
Contributor Author

I’ve prepared the necessary changes for the PR, but I’m unsure where VACUUM should be integrated in the code. If this direction looks good to you, I’d appreciate guidance or help placing it correctly.

@pajusmar pajusmar force-pushed the schema-compatibility branch 2 times, most recently from b3d5dca to e060d32 Compare March 1, 2026 12:11

@goodmami goodmami left a comment

Copy link
Copy Markdown
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Some suggestions, and I really don't think the COMPATIBLE_SCHEMA_HASHES set needs a new entry.

I'm still not sure we need to vacuum after removing (see discussion in the associated issue). But the change to the schema_hash function seems good once the comments are addressed.

Comment thread wn/_add.py Outdated
Comment thread wn/_db.py
Comment thread wn/_db.py
@pajusmar pajusmar force-pushed the schema-compatibility branch from e060d32 to 0211475 Compare March 1, 2026 22:08
@pajusmar pajusmar requested a review from goodmami March 1, 2026 22:18
@pajusmar pajusmar force-pushed the schema-compatibility branch from 0211475 to 5873498 Compare March 2, 2026 07:41
@pajusmar pajusmar marked this pull request as ready for review March 2, 2026 07:42

@goodmami goodmami left a comment

Copy link
Copy Markdown
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This makes sense. LGTM

@goodmami goodmami merged commit 55b6dd9 into goodmami:main Mar 18, 2026
11 checks passed
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.

Make schema hash resilient to SQLite maintenance operations (VACUUM, ANALYZE)

2 participants