You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
Commit abda8e7
Browse filesBrowse the repository at this point in the historyBrowse files
feat(workspace): tell the user which workspace skills a sync skipped, and why (#1374)
* feat(workspace): tell the user which workspace skills a sync skipped, and why
A skill that failed to sync was a log line only, so "nothing arrived" looked
exactly like "this workspace has no skills". Surface it instead:
- `syncSkills` now returns `skipped` (each skill with a short reason) and
`error` (set when the whole sync could not proceed: an unusable or foreign
folder, unreadable credentials, an unconfirmed workspace, an unreachable
skill list, or a failed publish).
- The per-turn sync shows a warning toast naming the skipped skills. The same
problem is announced once, not on every retry; a clean run clears it.
- `/workspace` Refresh folds skipped skills into its "problems" line, and the
`serve` refresh report carries `skillsSkipped` through to the IDE.
- Reasons are fixed, user-facing strings. The raw error can carry request
URLs, server text or local paths; it stays in the log.
Offline is reported at the binding lookup, not the list fetch: the binding is
re-resolved on the network, so an outage fails that first. Found in e2e — a
unit test that bound the project locally reached the list and missed it.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
* fix(workspace): address review on the skipped-skill warnings
- Headless `run` has no toast renderer, so print the warning to stderr there,
the same way the workspace engine reports.
- Clear the "already announced" latch inside `syncSkills` on any clean run,
so a clean Refresh or IDE refresh resets it too.
- Keep that latch in the process-global store, like the rest of this file's
state, so a second module record cannot fork it.
- Release the latch when the warning could not be shown (`notify` now reports
whether it published), but only if it still holds that problem.
- After a rebind or on a first sync, a failed pull no longer claims the
previous skills were kept — there were none left to keep.
- Cap the Refresh toast's skipped list the same way as the per-turn warning,
by reusing `describeSyncProblems`. The IDE route still gets every entry.
- Word a size mismatch as "its file size could not be verified": a valid
binary bundle mismatches too, so "incomplete download" misdiagnoses it.
- Test every skip reason, the kept-previous-copy suffix, the rebind wording,
the latch lifecycle, and that the route passes `skillsSkipped` through.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
* test(workspace): answer the binding lookup in `serveSkills`, and pin the rebind reason
`syncSkills` resolves the binding on the network every run. `serveSkills`
did not answer that lookup, so the mock threw, the lookup was swallowed as
"offline", and the new tests passed while running the stale-binding path
instead of the bound one. It now confirms the workspace each test binds to.
The rebind test also asserts the per-skill reason, so a regression that
promised "kept the previous copy" after a rebind would fail.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
* fix(workspace): address consensus review on the skipped-skill warnings
- Show a skill id sanitised and capped. An id that failed `safePathComponent`
is arbitrary text from the workspace service; control characters and line
separators reached the toast and the serve JSON as-is. The raw id stays in
the log.
- Stay quiet when a binding lookup fails for a project with no sign of a
workspace (no snapshot, no local binding). The server is always asked when
there is no local row, so offline warned in every opted-in repo, including
ones never linked.
- Say "it could not be saved on this device" for local write failures
(ENOSPC, EACCES, …) instead of blaming the download.
- Keep the per-turn warning when the skill registry refresh fails; it had
been skipped, for up to a poll interval after an account switch.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
---------
Co-authored-by: Claude Opus 5.5 <noreply@anthropic.com>
0 commit comments