Skip to content

K1: plane modes are families with typed absence; payload metadata is a family method - #1210

Merged
trissim merged 18 commits into
mainfrom
refactor/K1-plane-modes
Oct 12, 2026
Merged

trissim merged 18 commits into
mainfrom
refactor/K1-plane-modes

Conversation

@trissim

@trissim trissim commented Oct 12, 2026 •

Copy link
Copy Markdown
Collaborator

K1 · PR #1210 · guards 8/8 · production −1513 +1706 · tests −1693 +1898

Receipt: docs/refactor/consolidation-20261009/K1-plane-modes.md. Most of K1 landed through G3; this PR does the remainder.

What changed

  • One plane-axis family. RuntimePlaneAxis is an AutoRegisterMeta family (RuntimeSlicePlaneAxis, SourceBindingPlaneAxis, NoPlaneAxis); the enum-keyed strategy family and ImagePayloadMetadataCompositionMode (which restated it one to one) are merged into it and deleted.
  • Typed absence. plane_axis is always a member (NoPlaneAxis replaces None). A projection is a WholeAxisProjection or a SelectedPlaneProjection; RuntimePlaneProjection is a WholeStackProjection or a StackPlaneSelection. Only the selecting members have plane_index.
  • ObjectLabelDomainScope is a family that owns the behaviour of the former ObjectLabelPlaneDomainStrategy family.
  • Payload methods. image_metadata, array_data, scalar_source_provenance() and slice_source_provenances() are runtime-value family methods; image_metadata_of / array_data_of are deleted. G3's projection gate passes.
  • B5's G3 rows. Volume projection: three were a production bug (an absent scalar source record became an empty one in with_source_context_from), fixed; the fourth pinned behaviour Selected-plane artifact finalization fails with viewer streaming and no storage axes #395 changed on purpose and now asserts Selected-plane artifact finalization fails with viewer streaming and no storage axes #395's. Derived role: both were stale tests (the test bypassed the runtime's declared TIFF write).
  • E1's guard table loses the three enums' 36 rows.

Production adds 193 net lines: the family members, the four projection classes and their docstrings replace enum members and None checks; about 600 of the churn is the scope strategy classes moving above the dataclass that uses them.

Deletion certificates

  • derived: ImagePayloadMetadataCompositionMode (equalled RuntimePlaneAxis through for_plane_axis; the axis family now owns composition); RuntimePlaneAxisStrategy and leaves, ObjectLabelPlaneDomainStrategy (methods now on the family members); image_metadata_of / array_data_of (family methods); the "must be payload, plane, or None" TypeError in SourceImageObjectLabelBuildRequest.plane_semantics and the "requires a runtime-slice, source-binding, or channel axis" check in project_declared_source (the family has no other leading member; require_member validates at construction); the ObjectLabelValue type check moved from object_measurement_runtime_inputs to prepare_object_labels.
  • contract (runtime formats reset): plane_axis is spelled "none" instead of null in viewer image metadata, debug facts and CellProfiler profile fields.
  • tests-only: none.

Checks run locally

  • 30-workflow CellProfiler parity under the shared flock: 1 passed in 712.88s at 1f57f180a.
  • Structural ratchet (openhcs, scripts, benchmark): exit 0, empty delta. nra-r1: exit 0, "increased": [] (run with a 600 s budget; the machine was loaded).
  • 118 touched test files: 5 failed, 3960 passed, 4 skipped. The five: two integration tests that also fail on main (test_bbbc021_canonical_illum..., test_neurite_outgrowth_runs_on_synthetic_plate_as_2d_channel_stack); the zmq witness, which connects to other agents' execution servers on this machine and passes when run alone; two test_cellprofiler_library_loading tests that fail only in that combined run (a module registered by test_classification_interop_boundaries leaks across files) and pass alone; I did not run that combination on main.

🤖 Generated with Claude Code

trissim and others added 15 commits October 11, 2026 14:50
… and K8 files

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
…ily predicates

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
…n behaviour; E1 table rows removed

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
…_index None modes gone

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
…ojection gate passes

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
…n and derived-role tests pass

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
…lag reads

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
… own alias question

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Copilot AI balanced review requested due to automatic review settings October 12, 2026 00:40

Copilot AI left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

Copilot was unable to review this pull request because the user who requested the review has reached their quota limit.

trissim and others added 3 commits October 11, 2026 21:51
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>

# Conflicts:
#	openhcs/core/materialization/core.py
#	tests/unit/test_automatic_image_role_materialization_435.py
#	tests/unit/test_derived_role_publication_435.py
Conflicts: kinds.py keeps K7's compose_runtime_values/compose_runtime_groups
split and K1's RuntimeSlicePlaneAxis as the composition axis;
test_aligned_output_projection.py keeps K1's axis import and K7's context support.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
@trissim
trissim merged commit ae6ddac into main Oct 12, 2026
2 checks passed
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