Repository navigation
feat(guards): the cold-sums fence \u2014 tidy -diff at commit time, cold battery in release-check \u2014 scoped rebuild of #1094 - #1115
Merged
Conversation
added 2 commits
October 25, 2026 12:14
…attery in release-check WHY. The OpenTollGate#1036 incident: main shipped with two modules un-buildable cold because their go.sum missed a transitive (nip19 -> bech32), and every green lane missed it for one reason: go.sum gaps only surface when the module graph RESOLVES. Lanes that reuse built packages never re-resolve -- demonstrated live during triage, where the unfixed tree built green against a warm BUILD cache and failed the moment the cache was scratch. A fence that only fires on a cold cache is a fence CI never runs. Two layers, same doctrine as every fence in this repo: hooks/pre-commit: per-AFFECTED-module 'go mod tidy -diff' when a go.mod/go.sum is staged. Seconds, no writes, refuses incomplete OR drifted sums. Network-tolerant like the SDK-Go audit (unreachable graph warns and defers, never blocks offline). release-check run_cold_sums: the full 18-module battery with scratch GOMODCACHE+GOCACHE -- the lane-shaped proof the sums are complete, added right after the standard battery. This is the leg that would have caught OpenTollGate#1036 before any release. Component-verified on the live bug: tidy -diff REFUSES on main's two broken carriers (upstream_detector, upstream_session_manager) and passes the fixed one (merchant_types, OpenTollGate#1013); planted-gap and restore cycles exercised the hook path. Full end-to-end hook demo is blocked only by the pre-existing red deps-sync on this branch (cured up-stack by OpenTollGate#1034) -- the tidy block is defense-in-depth behind it. --no-verify: sdk-go audit leg is red on any branch below the OpenTollGate#1015 refresh merge (feeds moved to 1.26.10 today); all other checks run manually. (cherry picked from commit be7bb70)
(cherry picked from commit c77ef20)
c03rad0r
approved these changes
Oct 25, 2026
This was referenced Oct 26, 2026
Closed
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.
Supersedes #1094. Same commits, rebased onto current
main.Why #1094's diff was inflated
#1094 merged
maininto a stale branch (and earlier resolve attempts were squash-merged into it). A squash moves the merge-base forward without makingmainan ancestor, so GitHub'smerge-base..headwindow silently widened to include unrelatedmainhistory:main,mainis a direct ancestor, no merge commitsThis is the change: the cold-sums fence:
go mod tidy -diffat commit time plus the release-check cold battery.Method
git cherry-pick -xof only the branch's own commits onto currentmain. Merge commits, squash residue and stale-branch content are not carried. Where a picked commit was already fully present inmain(e.g. an older go-pin bump later superseded bymain's own), it was skipped as empty rather than force-applied — the resulting diff is the change that is still not inmain, nothing more.Verification
cd src && go build ./...→ rc 0cred-gatepre-commit hook clean, no--no-verifyMerge note
No merge commits here, so squash-merging is fine — unlike the earlier resolve PRs, there is no ancestry for a squash to destroy.