Skip to content

test(stage): give the stage doubles the in-flight layer hooks - #4704

Merged
Qubitium merged 1 commit into
mainfrom
test/stage-modules-dummy-looper-4679-followup
Nov 17, 2026
Merged

Qubitium merged 1 commit into
mainfrom
test/stage-modules-dummy-looper-4679-followup

Conversation

@Qubitium

Copy link
Copy Markdown
Collaborator

Summary

Test-only follow-up to #4546. run_layer_stage now records and clears the in-flight layer so a cancelled or failed quantize() restores the layer's placement, but the fifteen DummyLooper doubles in tests/test_stage_modules.py only model the stage protocol and were never extended. Seven tests have been red on main since that merge:

AttributeError: 'DummyLooper' object has no attribute '_track_inflight_layer'
AttributeError: 'DummyLooper' object has no attribute '_clear_inflight_layer'

Rather than fifteen copies, one shared _StageLooperDouble mixin provides the two no-ops and every double inherits it.

Validation

pytest tests/test_stage_modules.py -q → 52 passed (was 45 passed, 7 failed on unmodified main; I reproduced the same 7 failures on a pristine main worktree before changing anything).

ruff check tests/test_stage_modules.py clean.

No production code changes.

`run_layer_stage` records and clears the in-flight layer so a cancelled or
failed quantize restores its placement (#4546). The fifteen `DummyLooper`
doubles in `tests/test_stage_modules.py` only model the stage protocol and
were never extended, so seven tests failed on `main` with
`AttributeError: 'DummyLooper' object has no attribute
'_track_inflight_layer'`.

Add one shared mixin with the two no-ops instead of fifteen copies.
@Qubitium
Qubitium merged commit 6df9cae into main Nov 17, 2026
6 checks passed
@Qubitium
Qubitium deleted the test/stage-modules-dummy-looper-4679-followup branch November 17, 2026 10:21
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.

1 participant