Closed general

fusion_build_library_3d: save library 3D models into the run's project/folder, not the active project

John Lauer · 24d ago ·closed by Colby Knox

From adom-aiflow 0.2.3 (issue adom/adom-aiflow#74, item 6, reported by Muzzer; source read at fusion-bridge 1.11.43).

What happens today

fusion_build_library_3d (rust/bridge/src/mint.rs, build_library_3d_core) mints each part with make_3d_package. The in-app save in make3d_template.py saves each package .f3d to app.data.activeProject / Adom AI Workspace / <task> (task defaults to the library name). The projectId/folderId args only steer the APS upload fallback (discover_upload_target), and that fallback looks for "Adom AI Workspace" under one fixed root folder URN (KNOWN_ROOT_FOLDER), which belongs to one project.

So the models land in whatever project is active in Fusion's data panel. In Muzzer's run that was the user's unrelated "Bantam CNC" project, while the run saved the design to --project "Claude AI" --folder "Adom AI Flow".

What adom-aiflow does now (0.2.3)

adom-aiflow fusion library takes --project/--folder (kept for the run, and used by fusion schematic too) and sends them to fusion_build_library_3d as projectName and folderPath. Today the bridge ignores them; aiflow then says where the models went and suggests making the project active first.

Asked of the bridge

  1. fusion_build_library_3d and fusion_make_3d_package accept projectName and folderPath (names, as fusion_save_to_cloud takes them) and save each .f3d into <projectName>/<folderPath>/<task> (or a 3D models subfolder there) in BOTH paths: the in-app save (resolve the project by name instead of activeProject) and the APS fallback (resolve the project's own root folder instead of KNOWN_ROOT_FOLDER).
  2. Echo the destination in the reply and in fusion_prove_result (projectName, folderPath, and each part's fileId), so the caller can verify it.
  3. When the named project or folder does not exist: create the folder (never a project), or refuse with a clear errorCode; never fall back to the active project silently.

Acceptance

With project A active in the data panel, fusion_build_library_3d {..., projectName:"B", folderPath:"Adom AI Flow"} saves every package .f3d under B/Adom AI Flow, nothing new appears in A, the reply names B, and a design in B that uses the library renders the bound 3D (the wip_urns resolve in B).

1 Reply

Colby Knox · 16d ago

Fixed in fusion-bridge 1.12.0 (source commit b6fde85 on master; ships with the next release).

  1. fusion_make_3d_package and fusion_build_library_3d take projectName and folderPath. Each .f3d is saved into <projectName>/<folderPath>/<task>, with Adom AI Workspace when no folderPath is given. Missing folders are created; a project never is. The project is found by name in the hub, never taken from Fusion's active project.
  2. A missing project is refused with project_not_found and nothing is saved. When a save into a named destination fails, the bridge reports it and does not upload to the fixed APS folder, which belongs to another project.
  3. The reply's savedTo names the project and folder for each part. (fusion_prove_result does not echo it yet.)
  4. Without projectName the mint behaves exactly as before: the rendered script is byte-identical, and the existing parity tests pass.

Verified live on DESKTOP-BAR6S0F, with no project open in Fusion's data panel (the case that used to fall back to Main):

  • fusion_make_3d_package {projectName:"Default Project", folderPath:"fusion-lane-tests/lib3d", task:"issue-126"} on ADS8588SIPM saved ADS8588SIPM_3d.f3d in Default Project / fusion-lane-tests / lib3d / issue-126, and the reply said so. Nothing new appeared under Main / Adom AI Workspace.
  • projectName:"No Such Project" was refused with project_not_found, and nothing was saved.

AI Flow already sends projectName and folderPath to fusion_build_library_3d, so its runs pick this up once 1.12.0 is installed.

Colby Knox closed this · 16d ago

Log in to reply.