semcode-index: Exit non-zero when a lore archive fails - #94
Merged
Merged
Conversation
When semcode-index --lore cannot clone, fetch or index a lore archive,
it reports the error on stderr, moves on to the next archive, and still
exits with status 0. With explicit archive names it also counts the
failed archive in "Archives processed". A script or CI job that runs
semcode-index before querying lore therefore cannot tell a refreshed
archive from a stale one.
BPF CI ran into this. It switched from re-cloning the bpf archive on
every job to refreshing the copy baked into its image, and the fetch
failed because gitoxide had no committer for the reflog ("reflog
messages need a committer which isn't set"). The step still passed,
and reviews ran against the image's copy of lore, up to a day old.
Keep going with the remaining archives, list the failed ones in the
summary as the refresh path already does, and return an error at the
end if any archive failed.
Assisted-by: Claude:claude-opus-5-5
Signed-off-by: Ihor Solodrai <ihor.solodrai@linux.dev>
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.
When semcode-index --lore cannot clone, fetch or index a lore archive,
it reports the error on stderr, moves on to the next archive, and still
exits with status 0. With explicit archive names it also counts the
failed archive in "Archives processed". A script or CI job that runs
semcode-index before querying lore therefore cannot tell a refreshed
archive from a stale one.
BPF CI ran into this. It switched from re-cloning the bpf archive on
every job to refreshing the copy baked into its image, and the fetch
failed because gitoxide had no committer for the reflog ("reflog
messages need a committer which isn't set"). The step still passed,
and reviews ran against the image's copy of lore, up to a day old.
Keep going with the remaining archives, list the failed ones in the
summary as the refresh path already does, and return an error at the
end if any archive failed.
Assisted-by: Claude:claude-opus-5-5
Signed-off-by: Ihor Solodrai ihor.solodrai@linux.dev