Skip to main content

same_phase_in

Function same_phase_in 

Source
pub fn same_phase_in(
    left: &ErasedWorkflowView,
    right: &ErasedWorkflowView,
) -> Result<(), AssertionFailure>
Expand description

Checks that one case resolves to the same phase in two projections (I3).

“Exactly one phase” is a statement about a case, not about a view: a case that is Collecting when the typed workflow projects it and Dispatching when the erased registry projects the same state has two phases, however well each view checks out on its own. That happens for real — an erased projection deserializes the state through a second serde path, a second projector is written for a read model, a cached view survives a version bump — and none of the single-view invariants can see it.

The two views must be of the same case; a phase comparison across cases would be meaningless, so it is refused rather than answered.