Repository navigation
fix(skills): stop promising a skill update the command cannot deliver - #10436
Conversation
An "Update available" badge could never clear: pressing Update ran `npx skills update <name> --global`, which reported "All global skills are up to date" and wrote nothing, while the badge stayed on. Freshness marked a name updatable whenever ANY placement was outdated, including a standalone duplicate in an agent home. The global command only converges the canonical copy and its symlink aliases, so a stale duplicate kept the badge lit with no command that could clear it. - Count only reliably-convergent placements toward the update promise, so a stale duplicate no longer advertises an update that cannot land. - Give the duplicate chip a real skipped-reason instead of falling through to the generic sentence, naming the copy and how to resolve it. - Surface the existing freshness review dialog from the setup rails via a Details link, so a blocked or duplicate copy is explainable where the user actually sees the badge. Covers orchestration, Computer Use, Ephemeral VMs, Linear, the CLI section, the floating orchestration modal, the Browser Use card, and the Mobile Emulator row.
|
Note Reviews pausedIt looks like this branch is under active development. To avoid overwhelming you with review comments due to an influx of new commits, CodeRabbit has automatically paused this review. You can configure this behavior by changing the Use the following commands to manage reviews:
Use the checkboxes below for quick actions:
📝 WalkthroughWalkthroughGlobal skill update eligibility now ignores non-convergent outliers while preserving safety checks for canonical and supported alias placements. Freshness grouping and localized skipped reasons identify unreachable duplicates. Freshness display status adds 🚥 Pre-merge checks | ✅ 3 | ❌ 2❌ Failed checks (2 warnings)
✅ Passed checks (3 passed)
✨ Finishing Touches📝 Generate docstrings
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
… as all-clear A skill with an out-of-date copy the update command cannot reach rendered as a green "Installed" pill. That is honest about the main copy but reads as all-clear, so real drift in an agent home stayed invisible — the user had no reason to suspect there was anything to click. - Add a needs-attention display status (amber) for a placement that is not current but has no eligible update: stale duplicates, edited copies, read-only, inaccessible, and broken or external links. Presence-only stays green, and an unscanned inventory stays quiet so nothing flashes amber on launch. - State the reason inline on the setup rails, so the cause is readable without opening the review dialog; Details still opens the full per-location list. - Extract the skipped-reason sentence into its own module so the rails and the dialog share one source and can never drift apart. - Carry the state through the settings sidebar badge so the nav and the card cannot disagree.
There was a problem hiding this comment.
Actionable comments posted: 1
ℹ️ Review info
⚙️ Run configuration
Configuration used: Repository UI
Review profile: CHILL
Plan: Pro Plus
Run ID: 213de7e5-edf8-45a7-87eb-4bc3ddbd860c
📒 Files selected for processing (17)
src/renderer/src/components/settings/AgentSkillSetupPanel.tsxsrc/renderer/src/components/settings/SettingsSidebar.tsxsrc/renderer/src/components/skills/SkillFreshnessAttentionNotice.tsxsrc/renderer/src/components/skills/SkillFreshnessStatusPill.test.tsxsrc/renderer/src/components/skills/SkillFreshnessStatusPill.tsxsrc/renderer/src/components/skills/skill-freshness-group.tsxsrc/renderer/src/components/skills/skill-freshness-grouping.tssrc/renderer/src/components/skills/skill-freshness-skipped-reason.test.tssrc/renderer/src/components/skills/skill-freshness-skipped-reason.tssrc/renderer/src/i18n/locales/en.jsonsrc/renderer/src/i18n/locales/es.jsonsrc/renderer/src/i18n/locales/ja.jsonsrc/renderer/src/i18n/locales/ko.jsonsrc/renderer/src/i18n/locales/zh.jsonsrc/renderer/src/lib/settings-navigation-types.tssrc/renderer/src/lib/skill-freshness-display-status.test.tssrc/renderer/src/lib/skill-freshness-display-status.ts
🚧 Files skipped from review as they are similar to previous changes (5)
- src/renderer/src/i18n/locales/es.json
- src/renderer/src/i18n/locales/zh.json
- src/renderer/src/i18n/locales/ko.json
- src/renderer/src/i18n/locales/en.json
- src/renderer/src/components/skills/SkillFreshnessStatusPill.test.tsx
| return ( | ||
| <p className="mt-2 flex items-start gap-1.5 text-[12px] leading-snug text-muted-foreground"> | ||
| <AlertTriangle className="mt-0.5 size-3.5 shrink-0 text-amber-500" /> | ||
| <span>{reason}</span> | ||
| </p> |
There was a problem hiding this comment.
📐 Maintainability & Code Quality | 🟡 Minor | ⚡ Quick win
Amber icon color skips the dark-mode variant used elsewhere for this same warning treatment.
text-amber-500 has no dark: override, while the sibling amber "attention" treatment in skill-freshness-group.tsx (same PR) explicitly pairs light/dark shades (text-amber-700 dark:text-amber-400). For visual consistency across the skills UI in both themes, align this icon's color with that pattern.
🎨 Suggested fix
- <AlertTriangle className="mt-0.5 size-3.5 shrink-0 text-amber-500" />
+ <AlertTriangle className="mt-0.5 size-3.5 shrink-0 text-amber-600 dark:text-amber-400" />As per path instructions: "All UI work involving layout, color, typography, spacing, component selection, or UX behavior must follow docs/STYLEGUIDE.md, use tokens from src/renderer/src/assets/main.css... Do not invent documented color values."
📝 Committable suggestion
‼️ IMPORTANT
Carefully review the code before committing. Ensure that it accurately replaces the highlighted code, contains no missing lines, and has no issues with indentation. Thoroughly test & benchmark the code to ensure it meets the requirements.
| return ( | |
| <p className="mt-2 flex items-start gap-1.5 text-[12px] leading-snug text-muted-foreground"> | |
| <AlertTriangle className="mt-0.5 size-3.5 shrink-0 text-amber-500" /> | |
| <span>{reason}</span> | |
| </p> | |
| return ( | |
| <p className="mt-2 flex items-start gap-1.5 text-[12px] leading-snug text-muted-foreground"> | |
| <AlertTriangle className="mt-0.5 size-3.5 shrink-0 text-amber-600 dark:text-amber-400" /> | |
| <span>{reason}</span> | |
| </p> |
Source: Path instructions
The shared reason sentences are deictic — "this copy", "the copy here" — because they were written for the review dialog, where the location rows they describe sit directly beneath them. On the setup rails there are no rows, so "this" referred to nothing and the sentence read as if it were about the skill itself. Name the offending paths above the sentence on the rails, so the referent is present before the wording that depends on it. Every copy sharing the blocking reason is listed, not just the first, so resolving one does not leave the badge unexplained. The dialog keeps its existing wording and rows unchanged.
There was a problem hiding this comment.
🧹 Nitpick comments (1)
src/renderer/src/components/skills/SkillFreshnessAttentionNotice.tsx (1)
25-29: 📐 Maintainability & Code Quality | 🔵 Trivial | ⚡ Quick winUse documented typography tokens instead of arbitrary sizes.
text-[12px]andtext-[11px]bypass the renderer’s documented typography tokens. Replace them with the corresponding values fromdocs/STYLEGUIDE.mdandsrc/renderer/src/assets/main.css.As per coding guidelines: UI work must use the documented style-guide and asset tokens.
Source: Coding guidelines
ℹ️ Review info
⚙️ Run configuration
Configuration used: Repository UI
Review profile: CHILL
Plan: Pro Plus
Run ID: d5c1386d-726b-44c3-b632-4342d6aeeb24
📒 Files selected for processing (3)
src/renderer/src/components/skills/SkillFreshnessAttentionNotice.tsxsrc/renderer/src/components/skills/skill-freshness-skipped-reason.test.tssrc/renderer/src/components/skills/skill-freshness-skipped-reason.ts
Eligibility is now decided purely over the placements the global command actually converges — the canonical copy and its symlink aliases. A project skill, plugin cache, standalone duplicate, or unreadable copy in another agent's home used to withhold the update from the whole name. `skills update --global` provably never writes any of them, so that refused work the command could have done over a copy that was never at stake. A blocked *convergent* copy still withholds it: that is the placement the command writes to, and overwriting it is the real data-loss case. Also drop the inline reason from the setup rails. The reasons are written to sit beside the location rows they describe, so on a card they had nothing to point at and could only ever name one cause. The rails now mark Details with a warning icon when a copy needs the user's own hands, and the dialog does the explaining with every location and cause it knows about.
There was a problem hiding this comment.
🧹 Nitpick comments (3)
src/main/skills/skill-freshness-eligibility.ts (1)
6-16: 📐 Maintainability & Code Quality | 🔵 Trivial | 💤 Low valueCondense the explanatory comments. Keep only the non-obvious invariant; the implementation-level rationale is too verbose for the repository’s comment style.
src/main/skills/skill-freshness-eligibility.ts#L6-L16: reduce the docblock to the convergent-placement eligibility rule.src/renderer/src/components/skills/skill-freshness-skipped-reason.ts#L29-L31: reduce this to a short rendering-context note or remove it.As per coding guidelines, “Comments must be concise, limited to non-obvious information, and preferably one line.”
Source: Coding guidelines
src/renderer/src/components/skills/SkillFreshnessStatusPill.tsx (2)
59-61: 📐 Maintainability & Code Quality | 🔵 Trivial | ⚡ Quick winKeep this rationale comment concise.
This three-line comment explains implementation details. Retain only the non-obvious rationale, for example:
// The dialog provides location-specific causes; this link only opens it.Source: Coding guidelines
70-70: 📐 Maintainability & Code Quality | 🔵 Trivial | ⚡ Quick winUse renderer design tokens instead of raw Tailwind values.
text-[11px]andtext-amber-500bypass the requiredSTYLEGUIDE.mdandmain.csstoken contract. Replace them with the documented typography and attention-color tokens.Source: Coding guidelines
ℹ️ Review info
⚙️ Run configuration
Configuration used: Repository UI
Review profile: CHILL
Plan: Pro Plus
Run ID: 9fc102db-bb7f-4c71-904a-da83871c6883
📒 Files selected for processing (7)
src/main/skills/skill-freshness-eligibility.test.tssrc/main/skills/skill-freshness-eligibility.tssrc/main/skills/skill-freshness-inventory.test.tssrc/renderer/src/components/skills/SkillFreshnessStatusPill.tsxsrc/renderer/src/components/skills/skill-freshness-skipped-reason.test.tssrc/renderer/src/components/skills/skill-freshness-skipped-reason.tssrc/renderer/src/lib/skill-freshness-display-status.ts
🚧 Files skipped from review as they are similar to previous changes (1)
- src/renderer/src/lib/skill-freshness-display-status.ts
The review link rendered as bare text, so nothing but hover said it could be clicked — the badge told the user something was wrong and then gave them no visible way in. Use the ghost variant so it carries a hover/focus background and a real hit target instead of a zero-padding text run, and add a chevron so it reads as a control at rest. The chevron points right, not down: this opens the review dialog, while a down chevron already means the in-place expander inside that dialog.
…stablyai#10436) * fix(skills): stop promising a skill update the command cannot deliver An "Update available" badge could never clear: pressing Update ran `npx skills update <name> --global`, which reported "All global skills are up to date" and wrote nothing, while the badge stayed on. Freshness marked a name updatable whenever ANY placement was outdated, including a standalone duplicate in an agent home. The global command only converges the canonical copy and its symlink aliases, so a stale duplicate kept the badge lit with no command that could clear it. - Count only reliably-convergent placements toward the update promise, so a stale duplicate no longer advertises an update that cannot land. - Give the duplicate chip a real skipped-reason instead of falling through to the generic sentence, naming the copy and how to resolve it. - Surface the existing freshness review dialog from the setup rails via a Details link, so a blocked or duplicate copy is explainable where the user actually sees the badge. Covers orchestration, Computer Use, Ephemeral VMs, Linear, the CLI section, the floating orchestration modal, the Browser Use card, and the Mobile Emulator row. * fix(skills): say when a skill copy needs attention instead of reading as all-clear A skill with an out-of-date copy the update command cannot reach rendered as a green "Installed" pill. That is honest about the main copy but reads as all-clear, so real drift in an agent home stayed invisible — the user had no reason to suspect there was anything to click. - Add a needs-attention display status (amber) for a placement that is not current but has no eligible update: stale duplicates, edited copies, read-only, inaccessible, and broken or external links. Presence-only stays green, and an unscanned inventory stays quiet so nothing flashes amber on launch. - State the reason inline on the setup rails, so the cause is readable without opening the review dialog; Details still opens the full per-location list. - Extract the skipped-reason sentence into its own module so the rails and the dialog share one source and can never drift apart. - Carry the state through the settings sidebar badge so the nav and the card cannot disagree. * fix(skills): give the inline skill warning something to point at The shared reason sentences are deictic — "this copy", "the copy here" — because they were written for the review dialog, where the location rows they describe sit directly beneath them. On the setup rails there are no rows, so "this" referred to nothing and the sentence read as if it were about the skill itself. Name the offending paths above the sentence on the rails, so the referent is present before the wording that depends on it. Every copy sharing the blocking reason is listed, not just the first, so resolving one does not leave the badge unexplained. The dialog keeps its existing wording and rows unchanged. * fix(skills): stop withholding the update over copies it cannot reach Eligibility is now decided purely over the placements the global command actually converges — the canonical copy and its symlink aliases. A project skill, plugin cache, standalone duplicate, or unreadable copy in another agent's home used to withhold the update from the whole name. `skills update --global` provably never writes any of them, so that refused work the command could have done over a copy that was never at stake. A blocked *convergent* copy still withholds it: that is the placement the command writes to, and overwriting it is the real data-loss case. Also drop the inline reason from the setup rails. The reasons are written to sit beside the location rows they describe, so on a card they had nothing to point at and could only ever name one cause. The rails now mark Details with a warning icon when a copy needs the user's own hands, and the dialog does the explaining with every location and cause it knows about. * fix(skills): make the skill Details affordance read as a control The review link rendered as bare text, so nothing but hover said it could be clicked — the badge told the user something was wrong and then gave them no visible way in. Use the ghost variant so it carries a hover/focus background and a real hit target instead of a zero-padding text run, and add a chevron so it reads as a control at rest. The chevron points right, not down: this opens the review dialog, while a down chevron already means the in-place expander inside that dialog.
Fixes #10407
Summary
An "Update available" badge could never be cleared. Pressing Update ran
npx skills update orchestration --global, which reported "✓ All global skills are up to date" and wrote nothing — while the badge stayed lit. The user is left pressing a button that reports success and changes nothing, forever.Root cause
Orca and the
skillsCLI disagree about what "up to date" means, and the badge was reporting a state the offered command could not act on.eligibleSkillUpdateNamesmarked a skill updatable whenever any placement was outdated — including a standalone duplicate copy in an agent home (independent-copy). But--globalonly converges the canonical copy and its symlink aliases. So a stale duplicate kept the badge lit with no command in the UI that could ever clear it.Reproduced directly against
[email protected]in an isolatedHOME:npx skills update … --global✓ All global skills are up to date— duplicate untouchedUpdate available(never clears)What changed
1. Only promise an update the command can deliver —
skill-freshness-eligibility.tshasOutdatednow counts only reliably-convergent placements (canonical-copy/provider-alias).2. Don't withhold an update over a copy the command can't reach —
skill-freshness-eligibility.tsA project skill, plugin cache, standalone duplicate, or unreadable copy in another agent's home used to withhold the update from the whole name.
--globalprovably never writes any of them, so that refused work the command could have done over a copy that was never at stake. Eligibility is now decided purely over the placements it converges; a blocked convergent copy still withholds it, because that is the placement it writes to and overwriting it is the real data-loss case.3. Don't let honesty become silence —
skill-freshness-display-status.tsDropping the false promise is only half the fix. A skill whose copy is stale somewhere unreachable would have fallen back to a green "Installed" pill — accurate about the main copy, but it reads as all-clear and hides real drift, which is exactly what the freshness rail exists to prevent.
There is now a fourth status,
needs-attention(amber), for "a placement is not current but no update can reach it" — covering stale duplicates, edited copies, read-only, inaccessible, and broken or external links. Green now means only two things: presence-only, or genuinely verified current. An unscanned inventory stays quiet, so nothing flashes amber on launch.4. Mark the way in, and let the dialog explain —
SkillFreshnessStatusPill.tsxThe reasons are written to sit beside the location rows they describe, so on a card they have nothing to point at and can only ever name one cause. The rails mark Details with a warning icon when a copy needs the user's own hands; the dialog does the explaining, with every location and cause it knows about.
5. One source for that sentence —
skill-freshness-skipped-reason.tsThe reason text lived inside the dialog's group component. It is now its own module, so the rails and the dialog share one copy and cannot drift. The
duplicatechip — previously classed non-blocking and falling through to a generic sentence — got a real one:6. Reach every rail. Orchestration pane + setup card, Computer Use, Ephemeral VMs, Linear, CLI section (via the shared panel), the floating-terminal orchestration modal (which owned a hand-rolled
Installedpill and never showed freshness at all), the Browser Use card, the Mobile Emulator row, and the settings sidebar badge — so the nav and the card can never disagree. WSL keeps the presence-only pill, matching the existing local-host gate.Before / After
Both captured from an identical on-disk state — same scratch home, same skill files, only the build differs:
The main-process scan returns the same two rows on both builds. Only the verdict differs:
eligibleUpdateNames["orchestration"][]Before — the unclearable badge
"Update available", no way to learn why, and the Update button provably cannot clear it.
After — the problem is flagged, not hidden
Amber "Needs attention" — not a false promise, and not a green all-clear — with the review affordance marked so it reads as carrying a problem rather than a routine update.
After — an unreachable copy no longer withholds the update
Same three copies, canonical now stale. The update is offered again — it converges the canonical copy — and the warning still marks the copies it won't reach.
After — Details explains every location
Same three copies. Each is listed with its role —
Currentfor the main copy,Duplicatefor the stale one,Unrecognizedfor the locally edited one — beside the reason, which is where that wording belongs.After — a healthy skill stays quiet
Same build, duplicate removed. No amber, no notice, no Details — the new state does not over-warn.
Why this fixes the report
The reporter pressed Update, the CLI said "already up to date", and the badge stayed. Four things were wrong:
--globalnever touches. Badge and button now agree.needs-attentionkeeps the signal while dropping the false promise.Testing
pnpm lint(localization catalog + coverage, skill-bundle manifest, max-lines ratchet, switch exhaustiveness)pnpm typecheckskills/,settings/,lib/,floating-terminal/,feature-wall/,emulator-pane/,main/skills/cannot-update; the display status separates presence-only from needs-attention; the shared reason picks the harder blocker first; the pill shows/hides Details and opens the dialogHOME, before and after, plus the healthy caseNotes
updatevsaddquestion (skills updatetrusting its lockfile rather than the installed bytes — see [Bug] NPX skills update #6162) is deliberately left for a separate change.