Skip to content

fix: enable sqlite wal mode#908

Open
a1denvalu3 wants to merge 3 commits intomainfrom
fix-sqlite-pragma-rate-limit
Open

fix: enable sqlite wal mode#908
a1denvalu3 wants to merge 3 commits intomainfrom
fix-sqlite-pragma-rate-limit

Conversation

@a1denvalu3
Copy link
Collaborator

@a1denvalu3 a1denvalu3 commented Feb 26, 2026

Summary

  • Enables SQLite journal_mode=WAL and busy_timeout=5000 to improve database concurrency.

Resolves #907

@codecov
Copy link

codecov bot commented Feb 26, 2026

Codecov Report

❌ Patch coverage is 50.00000% with 1 line in your changes missing coverage. Please review.
✅ Project coverage is 62.96%. Comparing base (89564fe) to head (4814bbb).
⚠️ Report is 8 commits behind head on main.

Files with missing lines Patch % Lines
cashu/core/db.py 50.00% 1 Missing ⚠️
Additional details and impacted files
@@            Coverage Diff             @@
##             main     #908      +/-   ##
==========================================
+ Coverage   61.51%   62.96%   +1.45%     
==========================================
  Files          93       93              
  Lines       11051    11052       +1     
==========================================
+ Hits         6798     6959     +161     
+ Misses       4253     4093     -160     

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.

@a1denvalu3 a1denvalu3 force-pushed the fix-sqlite-pragma-rate-limit branch from 4a8924b to 0f34b40 Compare February 27, 2026 09:37
@a1denvalu3 a1denvalu3 force-pushed the fix-sqlite-pragma-rate-limit branch from 977885e to 4814bbb Compare February 27, 2026 22:58
@a1denvalu3 a1denvalu3 marked this pull request as draft February 28, 2026 10:59
@prusnak
Copy link
Contributor

prusnak commented Feb 28, 2026

Do we know why the tests fail?

@a1denvalu3 a1denvalu3 changed the title fix: enable sqlite wal mode and default rate limit fix: enable sqlite wal mode Mar 2, 2026
@a1denvalu3 a1denvalu3 marked this pull request as ready for review March 3, 2026 08:56
@a1denvalu3
Copy link
Collaborator Author

Do we know why the tests fail?

A read of a quote in one test was racing with a write. Added a delay and now it seems to work.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

Status: Backlog

Development

Successfully merging this pull request may close these issues.

SQLite: enable WAL mode and busy_timeout for concurrent write performance

2 participants