Repository navigation
Description
Symptom
A candy pinned to a branch or a 40-character SHA is downloaded and then discarded. The consumer builds from an older tag instead, with no error.
Measured in opencharly/distro-cachyos, box/nvidia pinned to layer-nvidia:fix/nvidia-ctk-repo:
$ charly box generate nvidia
Downloading github.com/opencharly/layer-nvidia:fix/nvidia-ctk-repo...
Notice: candy github.com/opencharly/layer-nvidia resolved to multiple git tags with differing content…
Notice: candy github.com/opencharly/layer-nvidia resolved to multiple git tags with differing content…
rc=0
$ grep -rl 'install nvidia-ctk from the Arch extra repo' .build/_candy/
(no output) # the downloaded ref's content is nowhere
$ ls -d .build/_candy/*nvidia*
.build/_candy/nvidia.7766a9d06ec5fe8c276c091a68fb72cea12688e3
.build/_candy/nvidia.v2026.320.1938 # the tag it fell back to
The generated Containerfile confirms the fallback: no line from the pinned branch appears, and the package line is the bare nvidia-container-toolkit the old candy emitted.
Reproduction
- Pin any
@github.com/…:<branch>or@github.com/…:<40-char-sha>in a box'scandy:list. charly box generate <box>— note theDownloading …line followed by the tag-resolution Notice.grep.build/_candy/for a string that exists only on the pinned ref — it is absent, and.build/<box>/Containerfilelacks the ref's contribution.
charly cache clear does not change the outcome (measured: git-ref cache cleared — the next resolution is fresh, same fallback afterwards). charly cache status reports entries: 532 (latest tags + default branches + resolved SHAs + downloads), so resolved SHAs are meant to be supported.
Why it matters
It makes a producer-first landing order impossible to verify locally. A consumer's bed can only run against a tag, and a tag only exists after a merge — so a candy PR cannot present the fresh-rebuild check-image proof that the review gate requires before that merge. That is the deadlock recorded on opencharly/layer-nvidia#23.
It also means an edit can be "verified" for many rounds against an artifact built from a different revision; this cost a substantial amount of wasted work here.
Suggested direction
Either honour a non-tag ref in the @github resolver, or fail loud and by name when a pinned ref cannot be resolved to content — the current behaviour is a silent fallback, which is the more damaging half.
Filed from
Assisted-by: DeepSeek Harness ollama-cloud deepseek-v4.1-flash (analysed on a live system)
Activity