Commit Graph

6 Commits

Author SHA1 Message Date
NiJingzhe a5e6bf8eb6 feat(core)!: QL-only topology enumeration — remove bare getter list form
Plural topology getters (get_edges/get_faces/get_wires/get_vertices/
get_solids/get_inner_wires/get_edge_occurrences and the Compound
variants) now accept ONLY an index. The no-argument list form raises a
SimpleCADError with migration guidance (enumerate via
ql.<kind>().resolve(shape), pick via get_X(index)). This closes the
selection channel that escapes the graph: Python loops over bare lists
lose the predicate, capture kernel artifacts (the periodic-face seam
edges that broke FCStd translation), and leave no cardinality contract.

- each shape class keeps its enumeration logic as private _iter_<kind>();
  indexed picks record geo-select nodes as before (contract test added);
  Compound getters gain the same indexed recording they lacked
- _TopologySelectionList (the __getitem__ recording vehicle, which also
  made get_X()[i] a silent escape hatch) is retired
- all 109 internal call sites, 165 test call sites, and 31 example call
  sites migrated: SDK/tests use the private channel, user-facing
  examples use ql.<kind>().resolve(...)
- QL _resolve_scope_items switches to the private channel; scene
  contract profile descriptions synced; error strings recommending
  bracket indexing rewritten
- skill docs: strict prohibition added to SKILL.md global rules (new
  rule 6), core README contract statement rewritten, solid/wire/face/
  shell/tagged_mixin pages re-exemplified with QL, geometric-validation
  anti-pattern section updated; mirrors rebuilt via tools/skillbuild.py

Gates: full suite 1418 passed / 5 skipped; translator suites 133 passed;
u_link stage verifiers + render check ALL PASS; scadpkg->FCStd
retranslation verified (5 visible deliverables, 167-object editable
tree).
2026-09-01 02:09:29 +08:00
NiJingzhe 3935173e55 feat(stdlib): add build_ball_bearing durable sub-assembly builder
Standard parts until now could only be consumed as runtime assemblies;
durable parents had to extract ring parts and re-declare bindings by hand
(the pattern examples 16 and 20 both copy). Add build_ball_bearing, which
returns an AssemblyBuildResult whose definition re-declares the stdlib
contract: public outer_axis/inner_axis over one internal
inner_outer_revolute, grounded on the outer ring by default (ground
selectable), returned unsolved so parent-level fixed constraints can drive
both rings. Part/assembly source capture is anchored to the stdlib package
directory so the builder works from any project root. Update the naming
contract to allow build_* durable builders beside make_*_r* runtime
factories and lock the nested dual-fixed behavior with a contract test.
2026-08-21 10:28:34 +08:00
NiJingzhe 2fc3029a86 refactor: split operator facade and public connectors 2026-08-20 14:52:07 +08:00
NiJingzhe f72e24e026 Optimize stdlib graph tracking 2026-07-23 04:23:00 +08:00
NiJingzhe d60b08d4c8 Expose bearing axis connectors 2026-07-06 17:46:22 +08:00
NiJingzhe 3fa3991a1d Refactor FreeCAD translator namespace 2026-07-06 01:55:01 +08:00