Repository navigation
maintain: heal the inventory a reconcile left behind - #574
Merged
Merged
Conversation
The refresh added with the reconcile only ran when the pass had deleted
something, so it prevented the false "possibly_stale" but did not heal the
two live projects the wave's first pass had already invalidated: their
watermark had moved, their summary had not, and the next pass found nothing
to delete and so refreshed nothing.
The rule is now the honest one: the reconcile makes the store's summary match
the store. The inventory is refreshed whenever it is behind the watermark,
and the refresh stays conditional because every content-writing path already
refreshes it (the CLI index, the core import, the watcher, the embedder, gc)
— so the pass does not write to every store every hour, and a summary that is
behind is one this pass (or an earlier one) invalidated.
Test: TestReconcileHealsAnInventoryLeftBehind — FAIL on origin/main ("the
pass must heal the inventory it left behind"), PASS here.
linhdmn
added a commit
that referenced
this pull request
Oct 22, 2026
…ips the wave (#577) The PRD named 0.35.2 while cmd/leankg/VERSION, the release stamp in internal/mcp/server.go, the published release (v0.35.3) and the installed binary were all 0.35.3. The reconciliation that stamped 0.35.2 ran before the 0.35.3 cut, and the cut moved the version past it again. v0.35.3 carries the wave's seven fixes and the two follow-ups (#573, #574); their subjects carry no conventional prefix, so release-please cannot classify them and the cut was declared with a Release-As trailer (the pattern AGENTS.md documents), with their changelog entries added by hand.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
The previous fix made the reconcile refresh the inventory only when the pass had deleted something. That prevents the false
possibly_stale— but it does not heal the two live projects the wave's first pass had already invalidated: their watermark had moved, their summary had not, and the next pass found nothing to delete and so refreshed nothing.The rule is now the honest one: the reconcile makes the store's summary match the store. The inventory is refreshed whenever it is behind the watermark — because this pass deleted content, or because an earlier pass did.
The refresh stays conditional, because every content-writing path already refreshes the inventory (the CLI index, the core import, the watcher, the embedder,
gc): so the hourly pass does not write to every store every hour, and a summary that is behind is one this pass (or an earlier one) invalidated.Test
TestReconcileHealsAnInventoryLeftBehind— FAIL onorigin/main:PASS here.
go build -p=2 ./...,go vet,gofmtclean;go test ./internal/maintain/ -count=1green.