Ratchet smells against pinned Hex packages - #30
Merged
Conversation
Run the smell engine over checksum-pinned Jason, Plug, Ecto, Phoenix, Decimal, Gettext, Floki, and Credo sources and compare stable finding identities with reviewed snapshots. Prefer the local Hex/Exograph tarball mirror, cache extracted source in CI, and fall back to Hex only when no local tarball exists. Also stabilize grouped fixed-shape-map locations exposed by repeated corpus runs.
dannote
force-pushed
the
smell-corpus-ratchet
branch
from
July 13, 2026 20:23
011e6ef to
a2cff86
Compare
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.
Summary
Add the CI-side corpus ratchet that complements Exograph's Hex-wide calibration.
Reach now runs its smell engine against checksum-pinned source snapshots of:
Each package's canonical
<relative-path>:<line> <kind>identities must exactly match its committed snapshot, so additions, removals, and location drift fail the default suite.Source handling
REACH_HEX_TARBALL_DIR/EXOGRAPH_TARBALL_DIRand the local/srv/toys/hex-mirror/tarballssnapshot.lib/**/*.ex; package code is never compiled or loaded.Exograph remains the broad design-time calibration/index layer. The ratchet deliberately consumes the local source mirror and runs Reach itself, keeping semantic CI validation independent of the Exograph service.
Determinism
Repeated corpus runs exposed unstable grouped
fixed_shape_maplocations caused by project map iteration order. This PR sorts occurrence locations before selecting the finding location/evidence and adds a regression assertion.Snapshot updates
Snapshots update only when explicitly requested with
UPDATE_SMELL_CORPUS_SNAPSHOTS=1; normal tests compare without writing.Validation
MIX_ENV=test mix compile --warnings-as-errorsmix testmix ci