Repository navigation
Conversation
Adds the `kicad` community UI plugin (external_plugins/kicad, source in ui-plugins/kicad, icon in assets/kicad, one marketplace.json entry). An agent can design a two-layer PCB with the user's local KiCad 10 (circuit spec -> real KiCad libraries -> auto-route -> DRC -> Gerber/BOM/pos), and the session side panel shows the result: 3D render, layers, schematic, DRC/ERC, library browser, artifacts and a live view of the open PCB Editor through KiCad's API. "Open in KiCad" exports a normal KiCad project; every save is imported back with a DRC run. Plugin type: UI Plugin (ui.surfaces[board], kicad_board_view _meta.ui). Version 0.6.0, category developer-tools, MIT.
Collaborator
|
✅ Internal validation passed. A ZCode maintainer will review the change next; after acceptance, release checks run separately and this PR is closed automatically. |
Collaborator
|
Thanks for your contribution! The change has been accepted by the maintainers. Publication to the marketplace is tracked separately; this contribution is now closed. |
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.
Plugin type (required) / 插件类型(必填)
Affected plugin name(s) / 涉及的插件名称:
kicad(UI Plugin)What / 改动内容
Adds the
kicadcommunity UI plugin (external_plugins/kicad, source inui-plugins/kicad, icon inassets/kicad, onemarketplace.jsonentry).User problem. An agent can design a two-layer PCB with the user's local KiCad 10 — circuit spec → real KiCad symbol/footprint libraries → auto-route → DRC → Gerber/BOM/pos — and the user sees and checks the result inside the conversation instead of in a pile of files.
Visible behaviour. A session side panel (
ui.surfaces[board], also shown inline forkicad_board_view) with tabs: Board (3D render, DRC verdict, part list), Live (the editor the user already has open, read through KiCad's own API), Layers, 3D views, Schematic, Checks (DRC + ERC), Library browser, Artifacts. "Open in KiCad" exports a normal KiCad project and opens the real PCB Editor; every ⌘S is imported back as a new artifact with a DRC run.Screenshots (the real ZCode window, a fresh profile, the plugin installed through the app's Plugin Marketplace; a real agent turn built the board):
UI integration. One
Appper page (official@modelcontextprotocol/ext-apps, handlers beforeconnect(), nowindow.zcode,availableDisplayModes: ["inline", "fullscreen"]), host theme/locale, widget state andmessage/updateModelContextonly behind capability checks,onteardown;kicad_board_viewcarries_meta.ui.resourceUri/surface; eight tools are app-only; the initial tool result is 2.1 KB structured / 0.4 KB content (host limits 64 / 32 KiB).Tested.
pnpm install --frozen-lockfile, the root builder staging,validate.py(48 plugins),build_dist.build_zip(32 files, 256 KiB, no binaries),test-mcp-app-artifacts.mjs(kicad PASS),oxlint(0 warnings in kicad),pnpm --filter @zcode/plugin-kicad test14/14 (also with a stdlib-only Python 3.12 and on a case-sensitive volume), the repository's Python unit tests 31/31,git diff --check.pnpm test:e2e: real KiCad 10.0.6 + headless Chrome through the official App/AppBridge handshake (20 checks, light/dark, en/zh).pnpm build/build_dist.pyfor all plugins (blocked here by photocraft's Rust toolchain), "Open in KiCad" against a real GUI.Version / registration. 0.6.0 in
plugin.json,marketplace.json,package.json; categorydeveloper-tools;componentTypes: ["ui"].Dependencies, network, side effects. KiCad 10 is used from the user's installation (not bundled). The MCP server is Python: it needs
uv(the plugin then fetches fastmcp, pydantic, numpy and optionally kicad-python on first start) or a Python ≥ 3.11 that has them; without either the plugin still starts, the panel says what to install (kicad_setup_help).uvruns withUV_NO_CONFIG=1. Commands run:kicad-cli, KiCad's bundled Python,uv, andopen -a "PCB Editor.app"on request. Files:./kicad/in the workspace (the file tools are confined to the workspace; nothing user-edited is overwritten) and the plugin data directory; KiCad runs on a private config so the user's~/Library/Preferences/kicadis never rewritten. The Live tab polls KiCad's local API socket while the panel is open. No hooks, no telemetry.Provenance / licenses. MIT.
server/kicad/is the author's own KiCad worker (placement, router, DRC, fabrication export); icon is original artwork (assets/icon-sources.json); bundled SDK notices indist/THIRD_PARTY_NOTICES.txt; KiCad (GPL-3.0-or-later, not redistributed), fastmcp, pydantic, numpy, kicad-python licenses listed in the README.Follow-up. An optional macOS-only part (an Edit tab that shows and operates KiCad's real windows through a small native helper app) is deliberately not in this PR; it is a separate stacked PR (0.7.0).
Self-check / 自查清单
external_plugins/kicad/categoryis set (developer-tools)versionbumped in BOTHplugin.jsonandmarketplace.json(new plugin, 0.6.0)README.md(EN) andREADME_CN.md(中文) both present and equivalentdescription_i18nhas bothenandzh-CNpython3 scripts/validate.pyandpython3 scripts/build_dist.pypass locally (build_dist for kicad alone: the rest of the repository's build is blocked here by photocraft's Rust toolchain)