Molecule path: step-export from the run folder loses every 3D model; project-page check flags test pads listed as BOM features

noah ·

What: two molecule-path problems met on one run (adom-aiflow 0.2.56+noah.1, KiCad 10.0.4 in the container):

  1. step-export runs kicad-cli on aiflow/run/board-N.kicad_pcb, where ${KIPRJMOD}/lib/... does not resolve (the project library is beside the original board, not in the run). The STEP is written with every component model missing; the diagnostics are only kind: model ("File not found ... Could not add 3D model"), and nothing blocks. molecule-publish then fails at the registry: convert-anchor: The STEP has no machine-pin bodies. Workaround: ln -s ../../kicad/lib aiflow/run/lib and export again. Suggest: resolve KIPRJMOD to the original project folder (or link its lib), and treat missing models as an error in step-export.
  2. project-page check reports components: no BOM row for TP1 ... TP13 while docs/bom.json lists them as feature: true lines (test pads). The check builds rows_refs from non-feature lines only. Workaround: clear the test pads' MPN in design/netlist.json.

4 Replies

John Lauer ·

Thanks Noah, two problems in one report, and both workarounds were clear.

1. step-export from the run folder lost every 3D model.

What was wrong: KiCad sets ${KIPRJMOD} to the folder of the board it opens, and step-export handed kicad-cli aiflow/run/board-N.kicad_pcb, so ${KIPRJMOD}/lib/... pointed into the run folder, where there is no library. The model warnings were classified (kind: model) but never counted as an open issue, so nothing told you the STEP had no parts until the registry said there were no machine-pin bodies.

What changed, in adom-aiflow 0.2.58:

  • step-export exports from the source board's project folder: a temporary copy of the run's board goes next to the original (it is removed right after), so ${KIPRJMOD} is your project and kicad/lib resolves without the symlink. An unset ${KICAD<N>_3RD_PARTY} is pointed at a kicad/3rdparty or 3rdparty folder with 3dmodels in the project folder or its parent. The record says what it chose (projectDir, exportContext).
  • Missing 3D models are now an open issue. You asked for them to be an error in step-export. AI Flow never refuses, so this is a finding instead: step-export reports the missing models with the first messages and the fix, and board-glb copper and deliver report the same open issue, until you export again with the models in place or record step-export --ack --why "..." for parts that have no model on purpose. For the same reason, board-glb copper and deliver now warn and carry on instead of stopping.
  • Verified by a new unit test: a board in proj/aiflow/run/ is exported by a fake kicad-cli that records its folder and environment. It runs in proj/ with KICAD10_3RD_PARTY=proj/kicad/3rdparty, leaves no temporary file behind, and a missing model shows as an open issue until acknowledged for that STEP. All suites pass.
  • Still open: when kicad-cli is the container shim (service-kicad or the desktop through Adom Bridge), only the board file travels, so the library is not there. The hint says to export on the desktop from the project folder and pass --log <output> --out <STEP>.

2. project-page check flagged test pads listed as BOM features.

I could not find this check in adom-aiflow 0.2.57: project-page-check (tools/project-page-check.py) checks page.json bindings, the datasheet text, README order and screenshots, and nothing in the package builds rows_refs, reads docs/bom.json or prints "no BOM row for". It looks like it comes from your local build (0.2.56+noah.1) or another package. If it is in a published package, tell me which command prints it and I will fix it there. The fix you describe is right: lines marked feature: true should count as covering their references.

Upgrade: tell your AI "give me the latest adom-aiflow" (or adom-wiki pkg install adom/adom-aiflow); adom-aiflow --version says 0.2.58.

Colby Knox marked this in progress ·
Colby Knox removed the in progress marker ·
Colby Knox marked this in progress ·
Colby Knox mentioned this in pull request #79 ·
Colby Knox ·

The step-export half is complete in adom-aiflow 0.2.62: exporting through the desktop stand-in (adom-aiflow-kicad-cli-remote) now keeps the 3D models.

  • The ${KIPRJMOD} models already travelled with the board.
  • Models under ${KICAD<N>_3RD_PARTY} in the project (step-export points it at kicad/3rdparty) travel too, and the variable is set to their folder on the desktop.

Still open: the project-page check "no BOM row for TP1" part. As John said, that check isn't in a published adom-aiflow. If you can tell us which command prints it, we'll fix it there.

Upgrade: tell your AI "give me the latest adom-aiflow" (or adom-wiki pkg install adom/adom-aiflow); adom-aiflow --version says 0.2.62.

Colby Knox removed the in progress marker ·
Colby Knox ·

Noah, one question so we can close the last part of this. The "no BOM row for TP1 ... TP13" message came from project-page check. That command isn't in AI Flow (not in 0.2.56 or since), so it may have been in your local 0.2.56+noah.1 build. Can you tell us where it came from (the command and the build that printed it)? If it was local, there's nothing left to fix on our side and I'll close this. If you'd like that check in AI Flow, a short note on what it should judge is enough, and I'll open it as its own request.

Colby Knox ·

A correction to my last comment: AI Flow does have adom-aiflow project-page-check (with a hyphen). It's a page preflight: explicit assets, GLB structure, PDF text, screenshots and section order. It has no BOM-row or test-pad check, though, so the "no BOM row for TP1 ... TP13" message still looks like it came from the check() in your tools/page-build.py, the same one #197 mentions. The question stands: if that check is from your build, it'll come in with the explorer PR (#197), and I'll close this.

Log in to reply.