app
KiCad - the KiCad Bridge
Public Made by Adomby adom
Reference implementation of the KiCad bridge: multi-instance Python server, forward path via kicad-cli, reverse path via in-process plugin. Most complex of the three bundled bridges.
← Commit history
0.9.292: Demo panel: reason is sent on every show (ab marks it required on show; a stage-advance show without it was refused live and the remote stayed at 1/7), and every show's reply is recorded on kicad_demo progress (panel: shown, stage, callbackUrl, error) so a refused show is visible instead of silent.
3 files changed
+9−6
BRIDGE_VERSION+1−1@@ -1 +1 @@-0.9.291+0.9.292
bridge.json+1−1@@ -2,7 +2,7 @@ "manifest_version": 1, "name": "kicad", "displayName": "KiCad EDA",- "version": "0.9.291",+ "version": "0.9.292", "description": "Reverse bridge for KiCad \u2014 board/schematic introspection, lint via kicad-cli, plugin install, multi-instance probe, in-process DRC.", "homepage": "https://wiki.adom.inc/adom/adom-bridge", "author": "Adom Inc.",
handlers/demo.py+7−4@@ -673,7 +673,10 @@ def _panel_show(stage: int, state: str | None = "playing") -> bool: return False try: from handlers import ad_client- args = {"action": "show", "id": _PANEL_ID, "stage": int(stage)}+ # reason on EVERY show: ab's verb marks it required on show, and a+ # stage-advance show without it was refused live (panel stuck at 0/7).+ args = {"action": "show", "id": _PANEL_ID, "stage": int(stage),+ "reason": "Transport for the KiCad tour the user started: play, pause, next, back, mute, stop"} if not _PANEL_SHOWN_ONCE["v"]: args.update({"title": "KiCad bridge tour", "stops": _PANEL_STOPS, "state": state or "playing", "position": "bottom-right",@@ -699,11 +702,11 @@ def _panel_show(stage: int, state: str | None = "playing") -> bool: data = (out or {}).get("data") if isinstance(out, dict) else None d = data or out or {} shown = bool(d.get("shown")) or (r.get("success") is True and not err)+ _job_update(panel={"shown": shown, "stage": int(stage), "callbackUrl": args.get("eventCallbackUrl"),+ "error": (err or d.get("error") or None),+ "reply": {k: d.get(k) for k in ("shown", "id", "state", "stage", "callbackAccepted", "error") if k in d}}) if shown: _PANEL["ok"] = True- if not _PANEL_SHOWN_ONCE["v"]:- _job_update(panel={"shown": True, "callbackUrl": args.get("eventCallbackUrl"),- "reply": {k: d.get(k) for k in ("shown", "id", "callbackAccepted", "error") if k in d}}) _PANEL_SHOWN_ONCE["v"] = True if state in ("playing", "paused"): _PANEL["scriptState"] = state