Repository navigation
🐛 fix(watcher): restore digest-based update detection for pinned semver tags (#498) - #500
Conversation
…er tags (#498) v1.5.0-rc.36 (#321) promised pinned tags would be 'compared by digest only', but shouldWatchDigestForUnlabeledImage() still disabled digest watching for specific semver tags — so pinned containers had no update detection at all, and the containers view showed a false 'compared by digest only' notice on every pinned container. - 🐛 fix: pinned specific semver tags now default to digest watching like floating tags; explicit dd.watch.digest=false still wins - 🐛 fix: the no-update notice no longer claims digest comparison is running when dd.watch.digest=false is set (pinned + floating branches) - 🔧 chore: remove the dead flat imgset tagFamily key (env-derived keys are lowercased, so it was unreachable; the documented nested TAG_FAMILY form is unaffected) - ✅ test: TDD coverage across docker-helpers/tag-candidates/orchestration/image-comparison/Docker.containers.details; stale Docker.test.ts digest-watch default expectation flipped - 📝 docs: watchers guide + FAQ pinned-tag digest default; CHANGELOG 1.5.2-rc.2 entry In agent deployments the agent performs the registry checks, so agents must be updated alongside the controller to restore digest detection for agent-watched containers. Fixes #498
|
The latest updates on your projects. Learn more about Vercel for GitHub.
|
|
No actionable comments were generated in the recent review. 🎉 ℹ️ Recent review info⚙️ Run configurationConfiguration used: Path: .coderabbit.yaml Review profile: CHILL Plan: Pro Plus Run ID: 📒 Files selected for processing (2)
🚧 Files skipped from review as they are similar to previous changes (2)
📝 WalkthroughWalkthroughDocker imgset configuration now accepts only nested 🚥 Pre-merge checks | ✅ 2✅ Passed checks (2 passed)
✨ Finishing Touches📝 Generate docstrings
🧪 Generate unit tests (beta)
Comment |
There was a problem hiding this comment.
Actionable comments posted: 2
🤖 Prompt for all review comments with AI agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.
Inline comments:
In `@app/watchers/providers/docker/image-comparison.test.ts`:
- Around line 542-546: Strengthen the test around the pinned-tag lookup by
asserting that every call to getImageManifestDigest uses tag.value equal to
'1.2.3', and optionally assert the expected call count. Update the test near the
existing result assertions so any semver-climbing lookup such as '1.2.4' or
'2.0.0' fails.
In `@app/watchers/providers/docker/tag-candidates.ts`:
- Around line 446-455: The disabled digest-watch guidance in the floating-tag
handling must mention both override paths: dd.watch.digest=false and
IMGSET_*_WATCH_DIGEST=false. Update the noUpdateReason message in the relevant
branch and its corresponding duplicate around the alternate return path to use
generic digest-watch override wording or explicitly reference both settings.
🪄 Autofix (Beta)
Fix all unresolved CodeRabbit comments on this PR:
- Push a commit to this branch (recommended)
- Create a new PR with the fixes
ℹ️ Review info
⚙️ Run configuration
Configuration used: Path: .coderabbit.yaml
Review profile: CHILL
Plan: Pro Plus
Run ID: dfa9b85c-da19-433e-8b19-3253756b59ec
⛔ Files ignored due to path filters (1)
CHANGELOG.mdis excluded by!CHANGELOG.md
📒 Files selected for processing (11)
app/watchers/providers/docker/Docker.containers.details.test.tsapp/watchers/providers/docker/Docker.test.tsapp/watchers/providers/docker/Docker.tsapp/watchers/providers/docker/docker-helpers.test.tsapp/watchers/providers/docker/docker-helpers.tsapp/watchers/providers/docker/docker-image-details-orchestration.test.tsapp/watchers/providers/docker/image-comparison.test.tsapp/watchers/providers/docker/tag-candidates.test.tsapp/watchers/providers/docker/tag-candidates.tscontent/docs/current/configuration/watchers/index.mdxcontent/docs/current/faq/index.mdx
💤 Files with no reviewable changes (1)
- app/watchers/providers/docker/Docker.ts
… notice CodeRabbit review on #500, both findings applied: - 🐛 fix: the disabled-digest-watch notice now names both override paths (dd.watch.digest=false label and imgset watch.digest=false), not just the label - ✅ test: pinned-tag digest lookup asserts the pinned tag is the ONLY manifest query, so a semver-climbing lookup can't regress unnoticed
biggest-littlest
left a comment
There was a problem hiding this comment.
Root cause verified: the rc.36 pin gate never had its promised digest path. Fix restores the announced contract without reversing the #321 default. Gate + TDD evidence checks out.
ALARGECOMPANY
left a comment
There was a problem hiding this comment.
LGTM — digest-watch default flip is scoped correctly, explicit overrides still win, honest notice copy.
…er tags (#498) (#500) Fixes #498. v1.5.0-rc.36 (#321) deliberately stopped pinned specific semver tags (e.g. `nginx:1.25.3`) from version-climbing, with the public promise that they would still be **compared by digest** — a rebuilt image republished under the same tag would be detected. That digest path was never enabled: `shouldWatchDigestForUnlabeledImage()` in `app/watchers/providers/docker/docker-helpers.ts` explicitly returned `false` for specific semver tags (a default inherited from the earlier Net default for every fully-pinned container since rc.36: - no semver candidates (the intended pin gate), **and** - no digest comparison (the bug) → zero update detection, and - the containers view shows a "Pinned tag … is compared by digest only" notice — which renders **only** when digest watch is off, i.e. it claims a comparison that isn't happening, on every pinned container. - Pinned specific semver tags now fall through to the same digest-watch default as floating tags. Explicit `dd.watch.digest=false` still wins (checked upstream, unchanged). Version climbing for pinned tags stays opt-in via `dd.tag.include` / `dd.tag.family=loose` — the #321 decision is not reversed. - The no-update notice is now honest in the one state it can still appear (explicit `dd.watch.digest=false`): it says digest watching is disabled instead of claiming a digest comparison is running. Same fix for the floating-alias strict-family branch. - Removed the dead flat `tagFamily` imgset schema key: env-derived config keys are lowercased by the loader, so it was unreachable; the documented `DD_WATCHER_{name}_IMGSET_{set}_TAG_FAMILY` (nested `tag.family`) form is unaffected. - The registry layer already rate-manages digest lookups (per-cycle digest cache, in-flight dedupe, token-bucket + retry in `BaseRegistry`/`Registry`), so the default flip rides existing throttling. - Agent deployments: agents perform the registry checks, so agents must be updated alongside the controller before agent-watched pinned containers regain digest detection (CHANGELOG notes this). TDD — tests written first and verified red against the unpatched source (7 failing), then the fix landed: - `docker-helpers.test.ts`: pinned-tag digest-watch defaults (Hub + non-Hub), explicit-override wins, meaningful-tag guard, dead imgset key no longer resolves - `tag-candidates.test.ts`: honest notice copy for pinned + floating branches when digest watch is off; `digest.watch=true` keeps `noUpdateReason` undefined - `docker-image-details-orchestration.test.ts`: end-to-end `digest.watch=true` for an unlabeled pinned container - `image-comparison.test.ts`: same-tag rebuild detection contract (digest update, no tag candidates) — the #321 promise - `Docker.containers.details.test.ts`: imgset schema rejects the dead flat key; nested `tag.family` still validates + applies - `Docker.test.ts`: stale `digest.watch` default expectation flipped (it asserted the bug) Full pre-push gate green: 100% app+ui coverage, tsc/vite builds, biome, qlty, zizmor. Ships as `v1.5.2-rc.2` (CHANGELOG heading included). rc.1's #496 fix rides along; soak restarts on the rc.2 delta. <!-- This is an auto-generated comment: release notes by coderabbit.ai --> - ✨ Added digest-watch test coverage for pinned specific semver tags (incl. same-tag rebuild detection) and orchestration behavior. - 🔧 Changed digest-watch defaults so pinned specific semver-like tags compare by digest by default, while still respecting `dd.watch.digest=false`. - 🔧 Updated digest-watch “no-update” notices and Docker docs to reflect the new defaults and the correct disablement paths (explicit `dd.watch.digest=false`, plus imgset `watch.digest=false`). - 🗑️ Removed the unsupported flat `imgset.<preset>.tagFamily` configuration/schema key; nested `imgset.<preset>.tag.family` is preserved. - ✨ Added/updated validation and regression tests for: - imgset schema (flat vs nested `tag.family`) - pinned-tag digest comparison querying only the pinned tag - overrides and notice messaging when digest watching is disabled - tag-candidates strict-mode `noUpdateReason` behavior - Update agents for agent-watched containers so they regain digest detection. -⚠️ Verify any existing user configs using the removed flat `imgset.*.tagFamily` key will fail validation and need migration to `imgset.*.tag.family`. - Ensure the change is targeted/rolled out for `v1.5.2-rc.2` as intended. <!-- end of auto-generated comment: release notes by coderabbit.ai -->
Fixes #498.
What's wrong
v1.5.0-rc.36 (#321) deliberately stopped pinned specific semver tags (e.g.
nginx:1.25.3) from version-climbing, with the public promise that they would still be compared by digest — a rebuilt image republished under the same tag would be detected. That digest path was never enabled:shouldWatchDigestForUnlabeledImage()inapp/watchers/providers/docker/docker-helpers.tsexplicitly returnedfalsefor specific semver tags (a default inherited from the earlier #178 floating-tag work).Net default for every fully-pinned container since rc.36:
The fix
dd.watch.digest=falsestill wins (checked upstream, unchanged). Version climbing for pinned tags stays opt-in viadd.tag.include/dd.tag.family=loose— the Can't set up auto updates to work #321 decision is not reversed.dd.watch.digest=false): it says digest watching is disabled instead of claiming a digest comparison is running. Same fix for the floating-alias strict-family branch.tagFamilyimgset schema key: env-derived config keys are lowercased by the loader, so it was unreachable; the documentedDD_WATCHER_{name}_IMGSET_{set}_TAG_FAMILY(nestedtag.family) form is unaffected.Notes
BaseRegistry/Registry), so the default flip rides existing throttling.Tests
TDD — tests written first and verified red against the unpatched source (7 failing), then the fix landed:
docker-helpers.test.ts: pinned-tag digest-watch defaults (Hub + non-Hub), explicit-override wins, meaningful-tag guard, dead imgset key no longer resolvestag-candidates.test.ts: honest notice copy for pinned + floating branches when digest watch is off;digest.watch=truekeepsnoUpdateReasonundefineddocker-image-details-orchestration.test.ts: end-to-enddigest.watch=truefor an unlabeled pinned containerimage-comparison.test.ts: same-tag rebuild detection contract (digest update, no tag candidates) — the Can't set up auto updates to work #321 promiseDocker.containers.details.test.ts: imgset schema rejects the dead flat key; nestedtag.familystill validates + appliesDocker.test.ts: staledigest.watchdefault expectation flipped (it asserted the bug)Full pre-push gate green: 100% app+ui coverage, tsc/vite builds, biome, qlty, zizmor.
Release
Ships as
v1.5.2-rc.2(CHANGELOG heading included). rc.1's #496 fix rides along; soak restarts on the rc.2 delta.Changelog
dd.watch.digest=false.dd.watch.digest=false, plus imgsetwatch.digest=false).imgset.<preset>.tagFamilyconfiguration/schema key; nestedimgset.<preset>.tag.familyis preserved.tag.family)noUpdateReasonbehaviorConcerns
imgset.*.tagFamilykey will fail validation and need migration toimgset.*.tag.family.v1.5.2-rc.2as intended.