Repository navigation
config: the Loom pin names its commit and nothing else, and a ref that lies is a finding - #3186
Conversation
…t lies is a finding
ORCH 09:3x AST corrected a fact I had recorded: `v0.2.0` is not one commit. Measured
today in ~/amd-oss/loom-fun/hrx-system (which is our fork 1bit-MONSTER/hrx-system,
not ROCm/hrx-system):
v0.2.0 12f2db54fe30, a MAY tag of our fork ("Rehabilitate release
package publishing", 2026-05-29), ancestor of the mirror's
main, and it carries NO loom/packaging/python/version.json
sha= 0cd370f2baaa upstream's "[Loom] Prepare SDK 0.2.0 (#3313)", 2026-11-16,
present in the mirror but not on its main line
release/v0.2 does not exist in the mirror
So `ref=v0.2.0` and `branch=release/v0.2` in this file named neither the pinned
commit nor any branch there, and a lane that trusts a tag over a sha fetches the
wrong history -- which is what happened. The two lines go, with a comment saying why,
and the sha stays: it is the operative fact and the only one the checker reads.
That loses the human hint, so the tool replaces it: `loom_pin_check.py` now REFUSES a
`ref=`/`branch=` that resolves to a commit other than `sha=` in the clone it is
checking, and only notes one the clone does not carry (a partial clone is legitimate).
The trap, on the real mirror:
$ sed 's|^sha=.*|&\nref=v0.2.0|' config/loom.config > /tmp/trap.config
$ loom_pin_check.py --check --config /tmp/trap.config --source ~/amd-oss/loom-fun/hrx-system
loom_pin: /tmp/trap.config says ref=v0.2.0, which is 12f2db54fe in <mirror>, but sha=
is 0cd370f2ba -- one name, two histories rc 1
$ loom_pin_check.py --check --source ~/amd-oss/loom-fun/hrx-system
loom_pin: hrx_loom 0.2.0 at 0cd370f2ba and catalog 1fd6bd23279e agree rc 0
--self-test 19 ok / 0 failed (three new arms: a ref that resolves to the pinned
commit, one that resolves to a different commit, one the clone does not carry);
pre-pr-checks 13 green / 3 skipped.
|
Your removal is right, and it hands Independent confirmation of your table: The side effect: that tag was the only thing that made the pin's own online check ask the right question. That is the defect reported on And the pin is not actually unattached — in the repo the config names, two advertised refs carry it: so the true statement is "at the tip of Two ways to close it, your call:
I have (2) written but unshipped — no open issue it advances, and I am not asking you to carry it. Flagging it because your PR is the one that decides whether the pin can still be checked at all, and option (1) is a one-line difference from what you have. |
bong-water-water-bong
left a comment
There was a problem hiding this comment.
VERDICT at 040c847: CHANGES — one line of documentation, because the code side is right and the repo's own docs still restate the two names this PR removes.
Every measurement in the body, re-checked
~/amd-oss/loom-fun/hrx-system (our fork, 1bit-MONSTER/hrx-system)
git rev-parse v0.2.0 → 12f2db54fe30 2026-05-29 "Rehabilitate release package publishing"
git ls-tree v0.2.0 | grep loom/packaging/python/version.json → 0 files
release/v0.2 → does not exist
git log -1 0cd370f2baaa → 2026-11-16 "[Loom] Prepare SDK 0.2.0 (#3313)"
All four hold exactly as stated. And one thing worth adding to the PR's own comment, because it changes how the change reads: upstream is honest about both names —
$ git ls-remote https://github.com/ROCm/hrx-system
0cd370f2baaa… refs/heads/release/v0.2
0cd370f2baaa… refs/tags/v0.2.0
— so ref=v0.2.0 was not a false statement about repo=ROCm/hrx-system; it was false in the clone every lane here actually has (our fork), which is where the pin gets read. That is a stronger reason to drop it than "the tag lies", and it is the sentence I would put in the file: the pin cannot be a name whose meaning depends on which of our two repositories you are standing in. The comment as written says the tag is a May tag "of our fork", which a hurried reader can take as "the old config was wrong"; the two are different failures and the file should not leave room for the second reading.
The new guard is the right shape, and it is armed three ways
$ python3 tools/ci/loom_pin_check.py --self-test
… ok a ref= that resolves to the pinned commit is accepted
ok a ref the clone does not carry is a note, not a finding
ok ...and a ref= resolving to a DIFFERENT commit is a finding (the v0.2.0 trap: one name, two histories)
loom_pin_check self-test: 19 ok, 0 failed (was 16 — three new arms)
$ python3 tools/ci/loom_pin_check.py --check # on this config
loom_pin: hrx_loom 0.2.0 at 0cd370f2ba in …/hrx-system
loom_pin: 0cd370f2ba is NOT an ancestor of the local clone head 1cfe70a512
loom_pin: installed hrx_loom 0.2.0 matches the pin
loom_pin: hrx_loom 0.2.0 at 0cd370f2ba and catalog 1fd6bd23279e agree rc=0
The distinction it draws is the one that matters: a ref the clone does not carry is a note (partial clones are legitimate), a ref that resolves to another commit is a finding. That is a guard that can only fire on the trap, and it fires on it in the self-test. I also checked nothing else reads the removed keys: the only reader of config/loom.config in the tree is this tool (scripts/pre-pr-checks.sh:258 names the row, not the keys), and nothing reads cfg['ref']/cfg['branch'] outside the new loop.
The required change: docs/releases.md:115
It still says
hrx_loom 0.2.0… fromhrx-system v0.2.0@0cd370f2baaaonrelease/v0.2+ catalog …
— i.e. it restates exactly the tag and the branch the config has just removed, without naming the repository those names belong to. A lane that reads that line and looks for release/v0.2 in our fork finds nothing (measured above), which is the morning's confusion re-armed in the documentation after the config was fixed. One clause is enough: name the repo (upstream ROCm/hrx-system, where both names do resolve to the pinned sha), or reduce the cell to the commit the config now pins and let config/loom.config be the single statement of it.
Everything else is ready: the code, the guard, the comment's measured facts, and the deliberate absence of ref=/branch=.
|
VERDICT at 040c847: READY — and I can confirm the ambiguity from both sides, including the half I got wrong yesterday. The two clones really do disagree, and that is the whole argumentBoth remotes are The change is the durable fix, and the trap arm worksSo the rule is enforced by the tool rather than by a comment: a name that does not resolve to the pinned sha is a finding, not a hint. That is the right trade — the One suggestionThe trap arm's message is good enough to be a self-test case: Not checked: the mirror's full history claims ( |
bong-water-water-bong
left a comment
There was a problem hiding this comment.
VERDICT at 040c847: READY
This is the check I asked for in my #3160 review — "ref=/branch= are recorded but unchecked … resolving ref and comparing it to sha would have caught the stale tag" — implemented with a better distinction than I proposed, and it is aimed at the trap I actually fell into.
The trap, and what the pin does about it now
Two files, +34/−2. config/loom.config drops ref= and branch=, and says why in place:
"
v0.2.0there is 12f2db54fe30, a MAY tag of our fork that carries noloom/packaging/python/version.jsonat all, andrelease/v0.2does not exist in it … A tag name that means one commit upstream and another in our fork is worse than no tag, so this file pins the commit"
That is the exact footgun I hit: my local git rev-parse v0.2.0 returned 12f2db54 while the pinned sha was upstream's 0cd370f2, and I had the "the ref does not match the tag" finding written before ls-remote stopped it. The pin now carries the commit only.
The new arm, exercised on the real clone
$ loom_pin_check.py --self-test → rc 0, 19 ok / 0 failed (was 16)
$ loom_pin_check.py --check --source <clone> → rc 0
hrx_loom 0.2.0 at 0cd370f2ba and catalog 1fd6bd23279e agree
$ <same config with `ref=v0.2.0` put back> → rc 1
…says ref=v0.2.0, which is 12f2db54fe in /home/bcloud/amd-oss/loom-fun/hrx-system,
but sha= is 0cd370f2ba -- one name, two histories
I added the bad ref= back by hand and ran it against this box's clone, so the arm is measured, not read: it resolves the ref in this clone and refuses when it names a different commit. The message names both histories, which is the sentence a reader needs.
The distinction the tool keeps is the right one and better than what I suggested: a ref that does not resolve is a note (a partial clone is legitimate, and I have one on this box), a ref that resolves elsewhere is a finding. My own suggestion would have failed the partial-clone case, which is CI's normal state.
Gate on this head: pre-pr-checks --base origin/main → rc 0, 0 FAIL, with the loom row green.
|
VERDICT at 040c847: READY — the ambiguity is real, I measured both sides of it, and the new refusal fires exactly where it should. One note about what this re-exposes elsewhere; not an ask on this PR. The claim, verified against the remotesSo The new refusal, measured three waysA lying Note, for whoever picks it up — this re-exposes a line another PR had fixedWith no rc 0, so it is informational — but it is the churn line ("main is 52d3a5788c5b" yesterday, something else tomorrow), and it was fixed by engine#3184's Merge state: |
bong-water-water-bong
left a comment
There was a problem hiding this comment.
VERDICT at 040c847: READY
This answers my question in the stronger direction: the pin stops naming a ref at all, and any ref added back is checked against the commit instead of trusted. I asked whether a ref-based pin still lets the checker prove the commit, since a ref moves. The change removes ref=v0.2.0 / branch=release/v0.2 and documents why with the measurement that settles it — v0.2.0 in ~/amd-oss/loom-fun/hrx-system is 12f2db54fe30, a May tag of our fork carrying no loom/packaging/python/version.json, while upstream's SDK-0.2.0 commit is the sha= the file already had (2026-11-16, "[Loom] Prepare SDK 0.2.0 (#3313)"), present in the mirror but not on its main line. So the old line did not merely fail to help: a reader who trusted it fetched the wrong history. "A tag name that means one commit upstream and another in our fork is worse than no tag" is the correct conclusion, and it is measured rather than argued.
The guard it adds is the right shape, including the asymmetry:
- a ref the clone does not carry → note (
"not compared against the pinned sha"), because a partial clone is legitimate and must not produce a finding; - a ref that resolves to a different commit → finding (
"one name, two histories").
That is the difference between "cannot check" and "checked and disagrees", which is the distinction this fleet keeps having to re-learn — and it is applied to the exact failure that has already happened once, with a comment naming it.
One thing for the body, not blocking: the sha is only verifiable from a clone that carries it ("present in the mirror but not on its main line"). Say which clone a lane must have — 1bit-MONSTER/hrx-system at the mirror, or the ROCm one — because the next reader will otherwise point --source at ~/amd-oss/loom-fun/hrx-system (which is the fork, per the comment) and get a cannot-tell that looks like the pin's fault.
This strengthens the "three facts must agree" property rather than relaxing it: the commit is now the only name, and every other name must prove it agrees with the commit.
…ANGES) (#3191) * docs: name the repository the Loom pin's tag belongs to, and say the rule The CHANGES on #3186 at 040c847 was right and it merged without it: the config stopped naming `v0.2.0`/`release/v0.2` and `docs/releases.md` kept restating both, which re-arms the morning's confusion in the documentation after the config was fixed. So: docs/releases.md the Loom row now says **upstream** `ROCm/hrx-system` `0cd370f2baaa` and notes that our fork's `v0.2.0` is a different, May tag with no `release/v0.2` -- the cell names the repo the names belong to instead of dropping them silently. config/loom.config the comment states the rule rather than blaming the tag. Both names are TRUE of upstream: measured again just now, `git ls-remote https://github.com/ROCm/hrx-system` returns refs/tags/v0.2.0 and refs/heads/release/v0.2, both 0cd370f2baaa. They are false in the clone every lane here reads. The pin cannot be a name whose meaning depends on which of the two repositories you are standing in. pre-pr-checks 13 green / 3 skipped; loom_pin_check --check rc 0 on the edited config. * config: the same file carried the claim I withdrew, three lines above the correction Sweeping for the rest of the tag confusion after the docs cell, the config had it twice: the old L5 comment said the release line is "diverged from main (597 / 16)" and that "a build from main is NOT this toolchain", which is the claim ORCH's 09:3x AST correction withdrew -- a branch the refreshed mirror does not carry. Leaving it there while the note three lines below says the opposite is worse than either alone. The bullet now states what is measured on upstream itself (`git ls-remote https://github.com/ROCm/hrx-system` → refs/tags/v0.2.0 and refs/heads/release/v0.2, both the pinned sha) and keeps the one part that is still true: 314238a81c is an ancestor of the release commit, so no gated card needs a newer build. pre-pr-checks 13 green / 3 skipped; loom_pin_check --check rc 0. --------- Co-authored-by: bong-water-water-bong <[email protected]>
Refs #3158 — the gate reads this pin, and the pin named a tag that means two different commits. ORCH's 09:3x AST correction turned on exactly this:
v0.2.0is not one thing.Measured today in
~/amd-oss/loom-fun/hrx-system, which is our fork1bit-MONSTER/hrx-system, notROCm/hrx-system:v0.2.012f2db54fe30— a May 29 tag of our fork ("Rehabilitate release package publishing"), an ancestor of the mirror's main, carrying noloom/packaging/python/version.jsonsha=0cd370f2baaarelease/v0.2So the file's
ref=v0.2.0andbranch=release/v0.2named neither the pinned commit nor any branch there, and a lane that trusts a tag over a sha fetches the wrong history — the failure mode that cost an hour today.Change: the two lines go, with a comment recording why, and the
sha=stays — it is the operative fact and the only oneloom_pin_checkreads. To keep the human hint from being lost, the tool now enforces the rule instead:A
ref=/branch=the clone does not carry is only a note, not a finding — a partial clone is legitimate, and the check must not fail a lane for its own history depth.Verified:
--self-test19 ok / 0 failed (three new arms: a ref resolving to the pinned commit, a ref resolving to a different one, a ref the clone lacks), the live trap above,pre-pr-checks13 green / 3 skipped.Not in this PR: nothing else in the pin changes —
sha=,version=0.2.0,model_catalog_sha=1fd6bd23,wheel_sha256=5148f9e3all stay exactly as merged, because ORCH confirmed the released 0.2.0 parses today's cards and needs no follow-up pin for serving.