Repository navigation
feat(app): serve the whole Skill Hub through the server and retire the Electron bridge - #368
Merged
Merged
Conversation
…e Electron bridge Single-skill browse, detail, and install join the Skill Stacks on the server's fork-only v2.skillhub group (skillhub.skill.list / get / install), and the app's Skill Hub pages call them over the SDK like the Stacks tab already did. The Electron IPC bridge — the main-process controller, its proxy warm-up, the preload namespace, platform.skillhub, and the app-owned wire types — is deleted; nothing desktop-side remains. That removes #363's off-host refusal rather than keeping it: the server downloads the skill and installs it where the agent runs, so "This project" is valid for every project the connected server knows — local, WSL, sandbox, or remote — and "project" is resolved server-side from the request's directory, never from a path the renderer sends. It also gives the web app the Skill Hub: the sidebar entry is no longer gated on a desktop capability. A newly installed skill is made visible to the model by disposing the instance, as the stack install already does. The sign-in offer on an auth failure stays, but only when the app's own SSO writes the session the server will read — i.e. when this machine is the server. Hub traffic now takes the sidecar's network path, which honours the system trust store and HTTPS_PROXY-style settings but not a proxy configured only through OS settings or a PAC file; the changelog says so. The plaintext netmind host in the detail page is base64'd like every other one in shipped source. Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01P1MfYkJD3tQZRgqBKB4gig
…ole page The live hub sends unset columns as null (`metadata.publisher`, `author.avatar`, …). The old desktop bridge never validated shapes, but the server's response schema types those fields as optional strings, so a single null card made the Skills tab 500 into "Something went wrong". Nulls now become absent fields at the package's coercion seam, once, so the CLI, the TUI, and the server's strict schema all see one total shape (avatar keeps its null: the hub means "no picture" by it). The exerciser fixture carries the same nulls so CI covers the class, and the browse pages print the server's own message under the generic line instead of hiding it. Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01P1MfYkJD3tQZRgqBKB4gig
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Both follow-ups from #367 in one PR: single-skill Skill Hub moves onto the server routes (which retires the Electron IPC bridge and #363's off-host block), and the Skill Hub gets a web entry point.
What changes
server.skillhubgroup:GET /api/skillhub/skill(browse with search/sort/domain/paging),GET …/skill/{idOrName}(detail with files inlined),POST …/skill/{id}/install(scope,agents,force). SameSkillHubErrorcodes as the stack routes; an existing install is refused withalready-installedunless forced, which is what drives the dialog's overwrite offer.packages/desktop/src/main/skillhub/(controller, IPC, test), the preloadskillhubnamespace,platform.skillhub,packages/app/src/skillhub/types.ts,desktop-only.tsx, the./skillhub/typespackage export, the desktop's@codev/skillhubdev-dependency, and the four IPC-era i18n keys in all three locales. Nothing desktop-side remains.scope: "project"is resolved server-side from the request's directory, never from a renderer-supplied path (closing the hole the IPCparseScopehad).SkillHubNavno longer gates on a desktop capability, so the web build reaches both tabs.platform.gatewaySso && server.isLocal()). Elsewhere the message points at the CLI.The one trade-off, stated plainly
#363 routed desktop hub traffic through Chromium's
net.fetchso system proxy settings and PAC files applied. Hub traffic now takes the sidecar's network path instead — the same one the server's model-gateway traffic already uses — which honours the system trust store (useSystemCertificates) andHTTPS_PROXY-style env settings (setGlobalProxyFromEnv), but not a proxy configured only through OS settings or a PAC file with no env vars. The CLI, TUI, and P3 Stacks tab already had exactly this exposure; this PR extends it to single skills in exchange for remote-server and web support. The changelog entry says so in user terms. If a PAC-only network turns out to matter, the fix belongs in the sidecar (resolving Chromium's proxy into env at spawn) and would cover the model gateway too.Verification
--include skillhub: 7/7 routes pass ineffect,coverage, andauthmodes (--fail-on-missing --fail-on-skip); the fake hub now also serves a skill listing, detail, and download ZIP through the package's injectable transport.packages/client16 pass;packages/apptest:unit823 pass / 0 fail. Both clients regenerated.DIVERGENCES.md: rows 224, 228, 230 rewritten (bridge gone), routes/generated/exerciser rows extended.CHANGELOG.md: fix(desktop): route Skill Hub through the proxy-aware stack and refuse off-host project installs #363's two Unreleased bullets replaced by one describing the new state.🤖 Generated with Claude Code
https://claude.ai/code/session_01P1MfYkJD3tQZRgqBKB4gig