Repository navigation
feat: freeze the public interface from v0.0.1 on, joined errors exit with the highest code - #57
Merged
Merged
Conversation
…with the highest code The project moves from "breaking changes permitted during 0.x" to a compatibility promise: from v0.0.1 on, the graft.toml/graft.lock formats (lock_version = 1), the content-hash algorithm, the exit-code semantics, and the environment variable names only change additively. The cache's internal layout and the status table layout are explicitly excluded (spec §9, §4.5; README stability note in both languages). Settled before the freeze closes the window: - Multiple collected errors (parallel apply) now exit with the highest code among them instead of the first in dep order, so an integrity failure (4) is never masked by a network error (3) — matching status's higher-code-wins rule. Spec §4.6 + REQ-EXIT-MAXCODE + clierr.ExitCode walking the joined-error tree. - The hash algorithm stays the spec'd sha256 set-Merkle (dirhash rejected) and the lockfile time field stays TOML datetime; decision records live in design.local §10.19. - The status table is declared human-only, not a stable interface; machine-readable output arrives additively later (§4.5). Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
Qodo reviews are paused for this user.Troubleshooting steps vary by plan Learn more → On a Teams plan? Using GitHub Enterprise Server, GitLab Self-Managed, or Bitbucket Data Center? |
Codecov Report❌ Patch coverage is
📢 Thoughts on this report? Let us know! |
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.
Why
The project moves from "breaking changes permitted during 0.x" to a compatibility promise: from v0.0.1 on, breaking changes are avoided. That closes the decision window on every pending format question, so they are all settled here, before the tag.
What
Policy (docs)
graft.toml/graft.lockformats (lock_version = 1), the content-hash algorithm (§3.2), the exit-code table + highest-code-wins rule (§4.6), and env-var names (§4.8) are stable fromv0.0.1; the cache's internal layout and thestatustable layout are explicitly excluded.statustable is declared human-only, not a stable interface — machine-readable output (e.g.--format json) will arrive additively.Settled decisions (records in design.local §10.19)
sha256:set-Merkle — dirhash rejected (was §11.5).timestays TOML native datetime (was §11.4).Behavior change + ratchet
clierr.ExitCodenow walks the whole error tree (includingerrors.Joinfrom a parallel reconcile) and exits with the highest code, so an integrity failure (4) is never masked by a network error (3) and the result no longer depends on dep ordering. Spec §4.6 (both languages) + newREQ-EXIT-MAXCODErow + covering test; testing manual note updated.Tests
go test -race ./internal/clierr/ ./cmd/...green locally;golangci-lint run ./internal/clierr/0 issues.TestExitCode_joinedErrorsHighestCodeWins(// spec: REQ-EXIT-MAXCODE) covers order independence, plain-error mixes, and wrapped joins.🤖 Generated with Claude Code