This Day In History For 2027-05-05
1 Year Ago (more context)
|
2026-05-05
| ||
| 15:15 |
•
Edit [faf57ad9c7]: Add tag "v0.6.0" with note "Release v0.6.0
- `Repo.Close` now runs `PRAGMA wal_checkpoint(TRUNCATE)` before closing the underlying connection, so the on-disk repo file is readable by external SQLite/fossil tooling. Previously, libfossil-managed repos could be left as a 4 KiB stub plus a fat WAL sidecar that vanilla `fossil` rejected as `not a valid repository`. (#27, #28) - New public `Repo.Checkpoint(mode)` method and `CheckpointMode` enum (`Passive` / `Full` / `Restart` / `Truncate`) for explicit mid-flight checkpointing. Long-running consumers (hubs, daemons) no longer need to reach through `Repo.DB().Exec("PRAGMA wal_checkpoint(...)")`. None. The Close error type may now be a joined error (`errors.Join(checkpointErr, closeErr)`) when both checkpoint and close fail; callers using `errors.Is` and `errors.As` continue to work. - No code changes required to benefit from the close-time checkpoint fix. - Callers running raw `PRAGMA wal_checkpoint` against `Repo.DB()` can switch to `Repo.Checkpoint(libfossil.CheckpointTruncate)` (or other modes) for a typed API surface. 9013d33 fix: checkpoint WAL on Close so vanilla fossil can read repo (#28)". artifact: 13ecfea3cf user: [email protected] | |
| 15:11 |
fix: checkpoint WAL on Close so vanilla fossil can read repo (#28)
Closes #27. libfossil opens repos in WAL journal mode but the Close chain never ran wal_checkpoint, so closed repo files were a 4 KiB stub plus a fat -wal sidecar. Vanilla fossil's validity probe stats the main file before consulting the WAL → repo rejected as "not a valid repository". - Adds a typed CheckpointMode (Passive / Full / Restart / Truncate) and a Checkpoint(mode) method on the public Repo (mirrored through internal repo and db.DB). CheckpointMode and its constants are re-exported from the package root so callers don't have to import db. - db.DB.Close now runs PRAGMA wal_checkpoint(TRUNCATE) before closing the underlying *sql.DB. Checkpoint errors are joined with the close error via errors.Join so the connection is always closed regardless of checkpoint outcome. - Skips the close-time checkpoint on the WASM/WASI build path where WAL isn't used. check-in: faf57ad9c7 user: [email protected] tags: trunk, v0.6.0 | |
| 15:11 | • Edit [faf57ad9c7]: Add tag "v0.6.0". artifact: 3aa664f6a3 user: [email protected] | |