app
Fusion - the Fusion 360 Bridge
Public Made by Adomby adom
Drive Autodesk Fusion 360 from the cloud via Adom Bridge: component libraries, IPC package generation, board layout, exports (STEP/Gerbers/BOM/CPL), fast APS cloud search, and parametric modeling.
← Commit history
Update 103 file(s)
9 files changed
+105−26
BRIDGE_VERSION+1−1@@ -1 +1 @@-1.9.321+1.9.322
adom-bridge-fusion-manifest.json+4−4@@ -1,10 +1,10 @@ { "manifest_version": 1, "name": "fusion360",- "version": "1.9.321",- "url": "https://wiki.adom.inc/download/adom/fusion-bridge/1.9.321/adom-bridge-fusion-v1.9.321.zip",- "sha256": "d3f15f4830e3431219c6bf71769685ec4e4181db1137744c4d3979735f860330",- "size": 601633,+ "version": "1.9.322",+ "url": "https://wiki.adom.inc/download/adom/fusion-bridge/1.9.322/adom-bridge-fusion-v1.9.322.zip",+ "sha256": "913b20c739ac50e1f48e25211499aeeca6d59493ae4027a9d696ef23b7b4d416",+ "size": 602868, "verbPrefixes": [ "fusion_" ],
bridge.json+1−1@@ -2,7 +2,7 @@ "manifest_version": 1, "name": "fusion360", "displayName": "Autodesk Fusion 360",- "version": "1.9.321",+ "version": "1.9.322", "description": "Drive Autodesk Fusion 360 from the cloud: launch Fusion, electronics board layout, design rules, exports (STEP/IGES/STL/3MF/USDZ/OBJ/DXF/DWG/Gerbers/BOM/CPL), fast APS server-indexed cloud search plus browse/recent/file-info/versions, cloud file download/upload and folder creation, and in-app parametric modeling (fusion_run_modeling_script). Never-charge: APS calls are capped to the free tier.", "homepage": "https://wiki.adom.inc/adom/fusion-bridge", "author": "Adom Inc.",
dashboard/Cargo.lock+1−1@@ -4,7 +4,7 @@ version = 4 [[package]] name = "fusion-dashboard"-version = "1.9.321"+version = "1.9.322" dependencies = [ "serde_json", ]
dashboard/Cargo.toml+1−1@@ -1,6 +1,6 @@ [package] name = "fusion-dashboard"-version = "1.9.321"+version = "1.9.322" edition = "2021" [dependencies]
install.sh+1−1@@ -21,7 +21,7 @@ echo "Installed fusion-bridge skills: $(ls "$PKG_DIR/skills" 2>/dev/null | tr '\ # binary (the three-artifact pattern: bridge zip -> ab, THIS pkg -> container skills + # this download, page media -> wiki). Per the wiki's PKG_VS_RELEASE policy, binaries are # platform-tagged RELEASE assets, never tarball content - the installer fetches them.-DASH_VERSION="1.9.321"+DASH_VERSION="1.9.322" DASH_URL="https://wiki.adom.inc/download/adom/fusion-bridge/${DASH_VERSION}/fusion-dashboard" DEST="" if [ -w /usr/local/bin ]; then DEST=/usr/local/bin
package.json+1−1@@ -1,6 +1,6 @@ { "slug": "fusion-bridge",- "version": "1.9.321",+ "version": "1.9.322", "type": "app", "description": "This package installs the bridge's SKILLS into your container so your AI knows how to drive it; Adom Bridge loads the bridge runtime itself from the release zip.", "dependencies": {
page.json+11−8@@ -1,6 +1,6 @@ { "slug": "fusion-bridge",- "version": "1.9.321",+ "version": "1.9.322", "type": "app", "description": "This package installs the bridge's SKILLS into your container so your AI knows how to drive it; Adom Bridge loads the bridge runtime itself from the release zip.", "dependencies": {@@ -11,6 +11,10 @@ "uninstall": "./uninstall.sh" }, "tags": [+ "ab",+ "bridge",+ "fusion",+ "desktop-app", "fusion360", "autodesk", "cad",@@ -75,7 +79,10 @@ "build a basic parts library", "add a 3d model to a component", "make a fusion 360 library with 3d",- "set up the fusion bridge"+ "set up the fusion bridge",+ "fusion dashboard",+ "fusion status page",+ "open the fusion launch page" ], "discovery_pitch": "Use the Adom Bridge Fusion 360 bridge when the user wants to DRIVE Autodesk Fusion 360 from the cloud: open/search their team's Fusion cloud designs, lay out a PCB or do electronics, export STEP/IGES/STL/Gerbers/BOM, or build a component library with real rendering 3D. It runs Fusion on the user's own machine via Adom Bridge. NOT for web/browser/login/form-filling (that's the native-browser extension) and NOT for KiCad (that's the kicad bridge).", "brief": "Drive Autodesk Fusion 360 from the cloud via Adom Bridge: component libraries, IPC package generation, board layout, exports (STEP/Gerbers/BOM/CPL), fast APS cloud search, and parametric modeling.",@@ -104,9 +111,5 @@ "label": "Part volume", "prompt": "How much material does each printed part in this assembly use?" }- ],- "author": {- "name": "John Lauer",- "email": "[email protected]"- }-}+ ]+}
server.py+84−8@@ -1509,6 +1509,26 @@ def _fusion_alerts(since_sec: float = 300.0, tail_bytes: int = 400000) -> list: return out +def _alert_watermark() -> str:+ """The stamp of Fusion's most recent alert RIGHT NOW.++ Every managed-library verb used to judge itself with _fusion_alerts(120), which reads a+ 120-second window and therefore blamed an action for an alert raised by whatever happened+ two minutes earlier - a clean unlink reported failure because of a stale "you decided not+ to synchronize" toast from a prior dialog. Take this before an action and pass it to+ _alerts_since so a verb only ever sees its OWN alerts."""+ rows = _fusion_alerts(3600.0)+ return (rows[-1].get("at") or "") if rows else ""+++def _alerts_since(watermark: str, since_sec: float = 300.0) -> list:+ """Alerts raised strictly AFTER the watermark stamp (see _alert_watermark)."""+ rows = _fusion_alerts(since_sec)+ if not watermark:+ return rows+ return [r for r in rows if (r.get("at") or "") > watermark]++ def _with_fusion_alerts(resp: dict, since_sec: float = 300.0) -> dict: """Attach Fusion's own alert toasts to a dialog report, so an in-canvas CEF error is never invisible just because it has no window (John, 2026-09-01)."""@@ -16106,12 +16126,55 @@ def _managed_precheck(require_hub=True): return (None, ctx) +_UPDATE_CHOICES = {"merge": "Merge Latest Version", "replace": "Replace Local Library",+ "cancel": "Cancel"}+++def _handle_update_prompt(choice="cancel", timeout_s=12.0):+ """Answer Fusion's "Would you like to force update your library to the latest version?"++ Linking a library to a managed library makes Fusion offer to pull that library's contents+ over yours, with buttons [Merge Latest Version] [Replace Local Library] [Cancel]. REPLACE+ DESTROYS the local library, so this defaults to Cancel: linking is a relationship, and+ overwriting a user's parts is never an implied consequence of asking for one. Callers opt+ in explicitly with onUpdatePrompt:"merge"|"replace".++ The dialog is CEF-drawn: UIA returns nothing for it, so it is answered by capturing the+ window and clicking through ab's image space (zero coordinate math on our side).+ """+ import time as _t+ label = _UPDATE_CHOICES.get(choice, "Cancel")+ win = _wait_for_top_window("Update", timeout_s)+ if not win:+ return None+ hwnd = win.get("hwnd")+ shot = _ad_call("desktop_screenshot_window", {"hwnd": hwnd}, timeout=60) or {}+ cm = _find_key(shot, "coordMap") or {}+ shot_id = cm.get("shotId")+ img = cm.get("image") or {}+ w = int(img.get("w") or (win.get("rect") or {}).get("width") or 0)+ h = int(img.get("h") or (win.get("rect") or {}).get("height") or 0)+ if not (shot_id and w and h):+ return {"prompt": "Update", "answered": False, "choice": label,+ "error": "Could not measure the Update dialog to answer it."}+ # The three buttons sit on one row near the bottom right, in the order merge/replace/cancel.+ frac = {"Merge Latest Version": 0.396, "Replace Local Library": 0.689, "Cancel": 0.903}[label]+ _ad_call("desktop_click", {"space": "image", "shotId": shot_id,+ "x": int(w * frac), "y": int(h * 0.824), "cursor": False,+ "reason": "answer Fusion's library Update prompt with %s" % label},+ timeout=25)+ _t.sleep(2.5)+ gone = _wait_for_top_window("Update", 5) is None+ return {"prompt": "Update", "choice": label, "answered": bool(gone), "dialogClosed": gone}++ def _handle_managed_library_push(fusion_info: dict, args: dict) -> dict: """Push a NEW VERSION of an already-linked managed library to library.io.""" err, ctx = _managed_precheck() if err: return err steps = []+ mark = _alert_watermark() menu_err = _libio_menu(ctx["win"], "push", "Push changes to library.io", steps) if menu_err: return menu_err@@ -16121,7 +16184,7 @@ def _handle_managed_library_push(fusion_info: dict, args: dict) -> dict: "dialog": dlg.get("title"), "_hint": "This library is not linked yet - Fusion offered Create Managed Library. " "Call fusion_managed_library_create instead (it completes that dialog)."}- alerts = _fusion_alerts(120)+ alerts = _alerts_since(mark) return {"success": not alerts, "library": ctx["doc"], "steps": steps, "alerts": alerts, "_hint": "A new version was pushed to the managed library." if not alerts else "Fusion raised an alert - read alerts[] and treat this as failed."}@@ -16133,11 +16196,15 @@ def _handle_managed_library_pull(fusion_info: dict, args: dict) -> dict: if err: return err steps = []+ mark = _alert_watermark() menu_err = _libio_menu(ctx["win"], "pull", "Pull changes from the managed library on library.io", steps) if menu_err: return menu_err- alerts = _fusion_alerts(120)+ prompt = _handle_update_prompt(args.get("onUpdatePrompt") or "merge")+ if prompt:+ steps.append(prompt)+ alerts = _alerts_since(mark) return {"success": not alerts, "library": ctx["doc"], "steps": steps, "alerts": alerts, "_hint": "Pull requested. Fusion greys this item out on a library that was never " "linked, so a silent no-op there is expected - link it first." if not alerts@@ -16150,11 +16217,12 @@ def _handle_managed_library_unlink(fusion_info: dict, args: dict) -> dict: if err: return err steps = []+ mark = _alert_watermark() menu_err = _libio_menu(ctx["win"], "unlink", "Unlink from the managed library on library.io", steps) if menu_err: return menu_err- alerts = _fusion_alerts(120)+ alerts = _alerts_since(mark) return {"success": not alerts, "library": ctx["doc"], "steps": steps, "alerts": alerts, "_hint": "Unlink requested. Fusion greys this item out on a library that was never " "linked, so a silent no-op there is expected." if not alerts@@ -16177,6 +16245,7 @@ def _handle_managed_library_link(fusion_info: dict, args: dict) -> dict: return err import time as _t steps = []+ mark = _alert_watermark() menu_err = _libio_menu(ctx["win"], "link", "Link to a managed library on library.io", steps) if menu_err: return menu_err@@ -16222,12 +16291,19 @@ def _handle_managed_library_link(fusion_info: dict, args: dict) -> dict: steps.append({"step": "confirm", "row": hit["name"], "clicked": bool(_find_key(ok, "success"))}) _t.sleep(2) gone = _wait_for_top_window("Select Managed Library", 6) is None- alerts = _fusion_alerts(120)- return {"success": bool(gone) and not alerts, "linkedTo": hit["name"], "library": ctx["doc"],+ # Fusion follows a link by offering to overwrite this library with the managed one.+ # Default to Cancel: the caller asked to LINK, not to have their parts replaced.+ prompt = _handle_update_prompt(args.get("onUpdatePrompt") or "cancel")+ if prompt:+ steps.append(prompt)+ alerts = _alerts_since(mark)+ return {"success": bool(gone), "linkedTo": hit["name"], "library": ctx["doc"], "managedFolder": hit.get("managedFolder"), "version": hit.get("version"),- "steps": steps, "alerts": alerts, "dialogClosed": gone,- "_hint": "The picker closed and Fusion raised no alert." if gone and not alerts else- "The picker is still up or Fusion alerted - treat this as NOT linked."}+ "steps": steps, "alerts": alerts, "dialogClosed": gone, "updatePrompt": prompt,+ "_hint": "Linked. Fusion offered to force-update this library from the managed one "+ "and that prompt was answered %r - pass onUpdatePrompt:'merge' to take the "+ "managed library's parts, or 'replace' to overwrite yours entirely."+ % ((prompt or {}).get("choice") or "not shown")} def _handle_library_manager(fusion_info: dict, args: dict) -> dict: