Migrate export_step / export_stl / export_brep off FreeCAD, onto build123d + OCP — Phase 6: Final cleanup — delete _freecad_import, prove no FreeCAD in export paths #46

Closed
opened 2026-06-24 03:24:35 +00:00 by Mark · 0 comments
Owner

Phase 6: Final cleanup — delete _freecad_import, prove no FreeCAD in export paths

Goal: Remove every FreeCAD/Part reference from the export paths.
Verify the acceptance criteria from the original spec are met.

Approach:

  • Delete pc2cad.py:3583 _freecad_import function (no callers remain
    after P1-P5).
  • Confirm git grep -nE "import (FreeCAD|Part)$" pc2cad.py returns hits
    only inside export_fcstd (which is intentionally kept gated).
  • Run the full verification command set from the spec; capture output
    for the closing comment.
  • Update pointcloud-to-cad-guide.md to remove FreeCAD install
    instructions from the export pipeline section.

Files: pc2cad.py:3583-3591 (delete), pointcloud-to-cad-guide.md
(doc update).

Acceptance:

  • git grep -nE "import (FreeCAD|Part)$" pc2cad.py returns hits only in
    export_fcstd.
  • All 6 spec acceptance criteria from the parent issue pass.
  • pointcloud-to-cad-guide.md no longer tells users to install FreeCAD
    for exports.

Out of scope

  • Rewriting _fit_* analytic primitive fitting — only the export is broken.
  • Touching the pc2cad_profile.py build123d path — already working; this
    rewrite converges on it, doesn't replace it.
  • Touching export_residual_mesh — open3d-based, unchanged.
  • FreeCAD GUI support for users who explicitly want it. The CLI does not
    expose export_fcstd; the function still works for direct callers.
  • Closes #2 (root cause of the sandbox / install failure).
  • Closes #6 (profile_extrude / profile_revolve now exported via the
    new path).
  • Depends on #22 having landed (it has — pc2cad_profile.py +
    pc2cad_cli.py::_export_build123d are merged and working).

Decomposed from pc2cad#23

## Phase 6: Final cleanup — delete `_freecad_import`, prove no FreeCAD in export paths **Goal:** Remove every FreeCAD/Part reference from the export paths. Verify the acceptance criteria from the original spec are met. **Approach:** - Delete `pc2cad.py:3583 _freecad_import` function (no callers remain after P1-P5). - Confirm `git grep -nE "import (FreeCAD|Part)$" pc2cad.py` returns hits only inside `export_fcstd` (which is intentionally kept gated). - Run the full verification command set from the spec; capture output for the closing comment. - Update `pointcloud-to-cad-guide.md` to remove FreeCAD install instructions from the export pipeline section. **Files:** `pc2cad.py:3583-3591` (delete), `pointcloud-to-cad-guide.md` (doc update). **Acceptance:** - `git grep -nE "import (FreeCAD|Part)$" pc2cad.py` returns hits only in `export_fcstd`. - All 6 spec acceptance criteria from the parent issue pass. - `pointcloud-to-cad-guide.md` no longer tells users to install FreeCAD for exports. --- ## Out of scope - Rewriting `_fit_*` analytic primitive fitting — only the export is broken. - Touching the `pc2cad_profile.py` build123d path — already working; this rewrite converges on it, doesn't replace it. - Touching `export_residual_mesh` — open3d-based, unchanged. - FreeCAD GUI support for users who explicitly want it. The CLI does not expose `export_fcstd`; the function still works for direct callers. ## Related - Closes #2 (root cause of the sandbox / install failure). - Closes #6 (`profile_extrude` / `profile_revolve` now exported via the new path). - Depends on #22 having landed (it has — `pc2cad_profile.py` + `pc2cad_cli.py::_export_build123d` are merged and working). --- _Decomposed from [pc2cad#23](https://forgejo.tail018ac4.ts.net/Mark/pc2cad/issues/23)_
Mark 2026-07-07 21:01:35 +00:00
Sign in to join this conversation.
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
Mark/pc2cad#46
No description provided.