inspector/clients/web/src/utils
Repository files (latest commit first)
Filename Latest commit message Latest commit date
cliffhall 9a8488681e feat: Skills extension phase 3 — CLI, TUI, directory reads, frontmatter check
Closes #2248.

Completes SEP-2640 support across all three clients, and closes the one
obligation #2234 deliberately left open.

- `checkSkillFrontmatterMatch` compares a served SKILL.md's own YAML
  frontmatter against the entry the listing advertised, field by field. No
  digest can cover this: a digest is taken over the bytes the server served,
  so it proves the file was not altered in transit and says nothing about
  whether the listing described it honestly. Needs a real YAML parser; `yaml`
  was already a root dependency, so this adds no package — but it does newly
  put it on core/'s import graph, hence the three bundler `external` lists.

- `resources/directory/read`: result schemas defined against the normative
  text, `InspectorClient.readResourceDirectory`, a Directory section on the
  Skills screen, and `--method resources/directory/read` in the CLI. The
  client refuses the call locally when the server did not declare
  `directoryRead`, which is the SEP's MUST NOT. A child the directory lists
  but the entry does not is marked `not listed` rather than merged into the
  manifest — the SEP calls a directory result a live observation and forbids
  treating it as extending the manifest.

- CLI: `skills/list`, `skills/get` and `resources/directory/read`, plus
  `--verify` — one NDJSON report per skill, a summary on stderr, exit 7 on a
  violation. Reads are sequential; a conforming manifest may declare 512
  entries.

- TUI: a Skills pane, shown only when the server declares the extension. Each
  row carries its conformance verdict as a glyph as well as a colour, since
  the pane is read over ssh and through script(1). Enter verifies.

- `verifySkills` re-throws `AuthRecoveryRequiredError` rather than recording
  it per file: it says the session's authorization expired, so absorbing it
  would report N identical read failures and swallow the error the TUI and
  the web commands key off to reauthorize.

Two open questions settled, both in code comments where they will be found:
`skills/get` carries no caching attributes because SEP-2640 leaves the
question open in as many words, so requiring them would fail a conforming
server; and there is no `PagedSkillsState` because every consumer of this
list is a whole-catalog verdict — computed over page one of three, "this
server's skills conform" is not merely partial but wrong.

The fixture grows two skills, both for checks that were otherwise
undemonstrable: `lying-listing` (listing and file disagree, digest still
verifies) and `stale-manifest` (serves a file its manifest does not declare).

Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01ND46Ci64DC3tzBy9aG81Nc
Signed-off-by: cliffhall <cliff@futurescale.com>
2026-09-07 18:10:37 -04:00
..
toasts fix: type-discriminate progress toast ids, CSPRNG attempt-id fallback 2026-09-05 13:36:30 -04:00
correlateTransportErrors.test.ts Network: modern Mcp-* headers, new error codes, cancellation-as-abort (#1628) (#1722) 2026-07-18 17:32:05 -04:00
correlateTransportErrors.ts Network: modern Mcp-* headers, new error codes, cancellation-as-abort (#1628) (#1722) 2026-07-18 17:32:05 -04:00
customHeaders.test.ts refactor(web): sharpen the src/lib vs src/utils rule and move misfiled modules (#1784) 2026-07-25 22:24:30 -04:00
customHeaders.ts refactor(web): sharpen the src/lib vs src/utils rule and move misfiled modules (#1784) 2026-07-25 22:24:30 -04:00
deepLink.test.ts web: deep-link auto-connect + machine-readable connection status (#1576) 2026-07-11 22:48:28 -04:00
deepLink.ts web: deep-link auto-connect + machine-readable connection status (#1576) 2026-07-11 22:48:28 -04:00
errorFormat.test.ts chore(web): move App.tsx's module-level block into files (#2127) 2026-08-26 18:07:40 -04:00
errorFormat.ts chore(web): move App.tsx's module-level block into files (#2127) 2026-08-26 18:07:40 -04:00
inferMimeFromUri.test.ts fix: address Copilot review round 7 (#2263) 2026-09-06 01:40:33 -04:00
inferMimeFromUri.ts fix: address Copilot review round 7 (#2263) 2026-09-06 01:40:33 -04:00
inspectorTabs.test.ts feat: support the Skills extension (SEP-2640) with digest verification 2026-09-04 20:45:15 -04:00
inspectorTabs.ts feat: support the Skills extension (SEP-2640) with digest verification 2026-09-04 20:45:15 -04:00
jsonObjectDraft.test.ts fix(web): reject an underflowing literal, and route embedded JSON resources 2026-08-27 06:26:23 -04:00
jsonObjectDraft.ts fix(web): reject an underflowing literal, and route embedded JSON resources 2026-08-27 06:26:23 -04:00
jsonUtils.test.ts fix: address Copilot review round 41 — const does not demand a property, required-only branches 2026-08-26 16:08:24 -04:00
jsonUtils.ts fix: address Copilot review round 41 — const does not demand a property, required-only branches 2026-08-26 16:08:24 -04:00
listRowKey.test.ts fix: key resource list rows by position so duplicate URIs cannot collide 2026-09-06 19:43:47 -04:00
listRowKey.ts fix: key resource list rows by position so duplicate URIs cannot collide 2026-09-06 19:43:47 -04:00
malformedListReport.test.ts fix: return the era-parsed tool, and hide aggregate reports in paginated mode (#1909) 2026-08-15 20:08:03 -04:00
malformedListReport.ts fix: return the era-parsed tool, and hide aggregate reports in paginated mode (#1909) 2026-08-15 20:08:03 -04:00
maskSecrets.test.ts feat(network): show auth response bodies with masked secrets + reveal toggle (#1386) (#1387) 2026-05-31 08:52:13 -04:00
maskSecrets.ts feat(network): show auth response bodies with masked secrets + reveal toggle (#1386) (#1387) 2026-05-31 08:52:13 -04:00
mcpNetworkHeaders.test.ts Network: modern Mcp-* headers, new error codes, cancellation-as-abort (#1628) (#1722) 2026-07-18 17:32:05 -04:00
mcpNetworkHeaders.ts Network: modern Mcp-* headers, new error codes, cancellation-as-abort (#1628) (#1722) 2026-07-18 17:32:05 -04:00
oauthClearKey.test.ts fix: resolve the clear's identity from the live client, in one place (#2217) 2026-09-04 00:02:45 -04:00
oauthClearKey.ts fix: resolve the clear's identity from the live client, in one place (#2217) 2026-09-04 00:02:45 -04:00
oauthFlow.test.ts Auth hardening CI gaps + SDK consolidation: EMA leg 2 / scopes (#1527) (#1725) 2026-07-19 22:36:21 -04:00
oauthFlow.ts Guided-auth removal, OAuth smoke testing, and TUI/CLI support (#1531) 2026-06-29 15:35:51 -04:00
oauthNetworkPhase.test.ts OAuth: re-key store to (server, issuer) + SEP-837/2350/2352 auth UX (#1694) 2026-07-16 16:52:53 -04:00
oauthNetworkPhase.ts OAuth: re-key store to (server, issuer) + SEP-837/2350/2352 auth UX (#1694) 2026-07-16 16:52:53 -04:00
oauthUx.test.ts All of the mid-session and step-up auth work 2026-07-02 16:35:31 -07:00
oauthUx.ts fix: report a terminal OAuth token-endpoint refusal instead of a dead retry 2026-09-07 09:09:54 -04:00
pendingReauth.test.ts All of the mid-session and step-up auth work 2026-07-02 16:35:31 -07:00
pendingReauth.ts refactor(web): sharpen the src/lib vs src/utils rule and move misfiled modules (#1784) 2026-07-25 22:24:30 -04:00
replayableProtocolMethods.test.ts chore(web): address Copilot review on #2127 2026-08-26 18:24:09 -04:00
replayableProtocolMethods.ts chore(web): address Copilot review on #2127 2026-08-26 18:24:09 -04:00
sandbox-csp.test.ts fix(web): state the expected shape when dropping a CSP source (#2064) 2026-08-24 01:02:02 -04:00
sandbox-csp.ts docs(web): describe the accepted subset, not "parses as a source expression" 2026-08-24 01:20:18 -04:00
schemaUtils.test.ts fix: centralize the nullable-union collapse in core and apply it in the TUI 2026-08-15 16:59:37 -04:00
schemaUtils.ts fix: centralize the nullable-union collapse in core and apply it in the TUI 2026-08-15 16:59:37 -04:00
serverSettingsDefaults.test.ts chore(web): move App.tsx's module-level block into files (#2127) 2026-08-26 18:07:40 -04:00
serverSettingsDefaults.ts chore(web): move App.tsx's module-level block into files (#2127) 2026-08-26 18:07:40 -04:00
serverWithDraftSettings.test.ts fix(auth): address Copilot review round 2 on the RFC 7009 revocation (#2144) 2026-08-28 01:47:48 -04:00
serverWithDraftSettings.ts fix(auth): address Copilot review round 2 on the RFC 7009 revocation (#2144) 2026-08-28 01:47:48 -04:00
stepUp.test.ts chore(web): move App.tsx's module-level block into files (#2127) 2026-08-26 18:07:40 -04:00
stepUp.ts chore(web): collapse App.tsx's six session refs into useSessionRef (#2129) 2026-08-26 20:43:29 -04:00
toolUtils.test.ts fix: address Copilot review round 40 — a required name counts as a field 2026-08-26 15:49:54 -04:00
toolUtils.ts fix: key resource list rows by position so duplicate URIs cannot collide 2026-09-06 19:43:47 -04:00
uriTemplate.test.ts fix: scope the value ceiling to the names a template references 2026-08-17 01:54:37 -04:00
uriTemplate.ts fix: scope the value ceiling to the names a template references 2026-08-17 01:54:37 -04:00