Skip to content

difftest: surface.surface_p6 real Sphere natural trims - #1047

Merged
bherbruck merged 3 commits into
tangency-labs:mainfrom
altvnk:fix/surface-p6-sphere-natural-trim
Oct 26, 2026
Merged

bherbruck merged 3 commits into
tangency-labs:mainfrom
altvnk:fix/surface-p6-sphere-natural-trim

Conversation

@altvnk

@altvnk altvnk commented Oct 25, 2026 •

Copy link
Copy Markdown
Contributor

Scoped completion claim

Units: surface.surface_p6.

In scope: add the existing real canonical radius-2 Sphere to this unit's generic
surface protocol, and one successful interior CreateNaturalUVTrimCurves fixture.
The current builders admit B-spline, Plane, Bounded and Revolution, but cannot
reach the existing Sphere iso-curve dispatch. No production algorithm is ported.

Expected edits:

  • crates/difftest/src/units/surface_surface_p6.rs
  • crates/solidcore-ffi/src/units/surface_surface_p6.rs
  • harness/cpp/shim/surface_surface_p6.cpp
  • fixtures/surface.surface_p6/sphere-natural-trim.json

Evidence: inspected main b206d3f5a38127dc3a0b6c511f1b45116826b341 lacks this
kind in its runner, FFI and native builder. A bounded, noncanonical Rust-only probe
constructed the actual Sphere and produced four spatial circles and four UV lines,
with finite complete samples on radius 2, orientations [2,1,1,2], zero gaps and
the expected rectangle boundaries. Actual NURB domain is [0,0,1,1]; the fixture
trim is [0.125,0.25,0.375,0.75], side U, remove=false, not angular STEP units.
This probe does not establish fresh-head or C++ parity.

Reviewed protocol: fixed canonical origin/X/Y/radius, new leaf tag 4, no payload
parameters. Support the ordinary recursive builder positions and existing operation
validation without a Sphere-specific whitelist. Preserve all old tag 0–3 branches,
guards and error ordering. The inherited B-spline-backed capability remains eligible
for the existing Scls filter; do not invent a plain-enum-kind refusal. Strong
four-edge/circle/geometry assertions belong only in this fixture's tests, never in
generic native admission or serialization. Existing dynamic trim records are reused.

Validation planned: focused identity/geometry/protocol/admission tests; complete
146-scalar native record comparison for the one ordinary fixture; an interior-only
perturbation control; the full unfiltered affected unit and its perturbation run;
formatting, CPP-enabled Clippy, independent exact-diff review, and all canonical
current-head gates including value-share and exact-base retention. Compile the
changed shim against the existing shared reference, read-only; no reference rebuild.
Any native mismatch, undefined-input concern or extra interface need blocks this
coverage-only scope rather than justifying a production change or narrower guard.

Preserve all 103 old fixtures, generator inputs/draws/seeds/minimum 2000, numerical
formulas, tolerances, floors, mismatch entries and status. No production, shared
interface, cache, plan, workflow or old-fixture edits.

Related PRs / dependencies: #1031 owns p8 boundary memoization and shared caches;
those paths/interfaces remain untouched. #1041 owns p9 analytic diagonal fixtures,
which are independent. #686's ellipse STEP/revolution work is not part of this scope.

Available follow-ups: other Sphere operations, poles, removal modes, wrapper
positions and other analytic kinds are not newly demonstrated by this fixture.
Generic admission is not a coverage claim for them.

Status / blockers / next step: scoped draft; implement the reviewed generic leaf
and one named fixture, establish native equivalence, then await exact-head canonical
CI. Maintainers retain workflow authorization, approval, queue admission and merging.

Published draft: exact-head evidence

Head 324fc862a7a44af221a5bbd60c31b10606bf9832, safely synchronized with authoritative main f4d002bb0a6dc5d49928a80213eb9ade8cdab7bd.
Independent FINAL review accepted fingerprint 13591b6c18c55463e342ee321222f98a14f074fe5703ef23a7e4dac9e4940767; reviewed
binary PR diff and all103oldfixtures/generator inputs remain unchanged across merge.

3 focused CPP runner tests and1FFI admission test passed
PASS surface.surface_p6 cases=2104 passed=2104 failed=0 deferred=0 max_rel_err=0e0 with_values=2104 no_values=0 vacuous=0
SENSITIVE surface.surface_p6 perturbed=2104 detected=2104 unperturbed=0 deferred=0
CPP-enabled Clippy both changed Rust crates, all-targets -D warnings: PASS
workspace formatting and diff checks: PASS
Operation / symbols Implementation Successful native comparison Remaining gap
Sphere CreateNaturalUVTrimCurves, named interior U case Generic real radius2 Sphere leaf added in unit-local builders; existing production operation unchanged Complete146-scalar records compare with max relative error0; four spatial curved edges and four UV lines, orientations/gaps/radius2/UV-boundary checks; interior-only perturbation detected Only this interior U/remove=false case adds geometry coverage; other admitted modes/wrappers/operations unproven

Rust tests assert concrete Sphere/Ellipse-circle/UV-Line identities. Native uses
real SmSphere construction; nondegenerate iso class identity is source-backed, not
a new runtime class export. Shared reference hashes/mtimes unchanged, no rebuild.
This is local macOS evidence, not canonical Linux or full completeness proof.
Ready for review by explicit user instruction; canonical CI is still pending.

User-authorized review status

Marked ready for review at the user’s request after local native validation and independent source review. Canonical CI was authorization-blocked at the latest audit; this transition does not claim green CI, approval, queue admission or merge readiness. Maintainer workflow authorization and all required checks remain mandatory. No source commit or workflow configuration changed.

Co-Authored-By: GPT-6.1 Sol Fast <noreply@openai.com>
altvnk and others added 2 commits October 26, 2026 00:59
Add the fixed canonical Sphere to the generic p6 surface protocol and compare
complete spatial/UV trim records without changing production geometry, old
guards, fixtures, generator inputs or numerical tolerances.

Co-Authored-By: GPT-6.1 Sol Fast <noreply@openai.com>
Co-Authored-By: GPT-6.1 Sol Fast <noreply@openai.com>
@altvnk

altvnk commented Oct 26, 2026

Copy link
Copy Markdown
Contributor Author

@bherbruck — exact published draft head 324fc862a passed independent final source review and local3CPP+1FFI tests, full native surface.surface_p6 2104/2104 cases, perturbation2104/2104, CPP-enabled Clippy and formatting. All103oldfixtures, generator inputs/seeds/min2000, guards and tolerances remain unchanged. Canonical run40248128556 requires authorization and has executed zero jobs. Please inspect/authorize it; draft remains pending all13 canonical jobs including native/value-share/exact-base retention. No technical CI failure or merge-readiness claim.

@altvnk
altvnk marked this pull request as ready for review October 26, 2026 00:38

@bherbruck bherbruck left a comment

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Approved by the automated first-pass review: CI green, mergeable, no CI/build/dependency file changes, no red-flag patterns in added code (process/network/env/unsafe outside FFI/blobs/hidden unicode), 0 known-mismatch entries added. Logic is gated by CI and the difftest merge queue.

@bherbruck
bherbruck added this pull request to the merge queue Oct 26, 2026
Merged via the queue into tangency-labs:main with commit b4f77f2 Oct 26, 2026
13 checks passed
@altvnk
altvnk deleted the fix/surface-p6-sphere-natural-trim branch October 26, 2026 20:20
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants