fix(tests): clear pre-existing full-suite reds (INV-21 pins + rotor_power)
Five fast-lane failures on main made the full suite dishonest. - Refresh INV-21 allowlist pins in demo tests for holographic_vault (ADR-0241) - Skip non-powerable (mixed-parity) rotor_power calls in generate recall and session anchor pull instead of crashing the cognitive path - Align session_anchor_pull fixture to grade-1 field parity - Ledger: docs/analysis/full-suite-reds-ledger-2026-07.md [Verification]: targeted 10 passed; lane SHAs 9/9; smoke 175 passed
This commit is contained in:
parent
ccc42c18de
commit
dddd85cfca
6 changed files with 96 additions and 3 deletions
72
docs/analysis/full-suite-reds-ledger-2026-07.md
Normal file
72
docs/analysis/full-suite-reds-ledger-2026-07.md
Normal file
|
|
@ -0,0 +1,72 @@
|
|||
# Full-suite reds ledger — 2026-07
|
||||
|
||||
Operator: Grok-4.5 (W2 pre-existing reds sweep)
|
||||
Branch: `fix/pre-existing-test-reds-v2`
|
||||
Base: `forgejo/main` @ `54228d45`
|
||||
|
||||
## Enumeration
|
||||
|
||||
| Lane | Command | Result |
|
||||
|------|---------|--------|
|
||||
| Fast | `pytest -m "not quarantine and not slow" -n auto -q` | **5 failed**, 11660 passed, 106 skipped (pre-fix) |
|
||||
| Fast recheck | same after fix | (see verification below) |
|
||||
| Slow | `pytest -m "slow and not quarantine" -n auto -q` | running / recorded at PR time |
|
||||
| Full | `pytest -m "not quarantine"` | union of fast + slow |
|
||||
|
||||
The brief’s “~31 reds” appears to reflect an older main tip. On current `forgejo/main`, the **non-quarantine fast lane** surfaces **exactly 5** dedicated failures. Smoke/pack/lane gates stay green because they never execute these nodes.
|
||||
|
||||
## Red list and disposition
|
||||
|
||||
| # | Test | Class | Cause | Disposition |
|
||||
|---|------|-------|-------|-------------|
|
||||
| 1 | `tests/test_deductive_entailment_authority_demo.py::test_inv21_and_inv29_allowlists_are_unchanged` | (b) pin drift | Demo pin omitted ADR-0241 writer `core/physics/holographic_vault.py` already on canonical INV-21 allowlist | **Fixed test** — pin updated to match `ALLOWED_VAULT_WRITERS` |
|
||||
| 2 | `tests/test_proof_carrying_promotion_demo.py::test_inv21_and_inv29_allowlists_are_unchanged` | (b) pin drift | Same as #1 | **Fixed test** — same pin update |
|
||||
| 3 | `tests/test_engine_loop_proof.py::test_generated_final_state_satisfies_versor_condition_by_construction` | (b) producer | `_recall_state` called `rotor_power` on mixed-parity transitions (multi-token even field ↔ grade-1 vault hit → odd unit versor). Exact `rotor_power` correctly refuses non-rotors | **Fixed producer** — `generate/stream.py` skips non-powerable weighted hits (`try/except ValueError`) |
|
||||
| 4 | `tests/test_register_pack_convivial_v1.py::test_runtime_chat_turn_idx_distinct_under_convivial` | (b) producer | Session anchor pull called `rotor_power` on non-rotor transition during `finalize_turn` | **Fixed producer** — `session/context.py` skips pull when power fails |
|
||||
| 5 | `tests/test_session_coherence.py::test_session_anchor_pull_output_satisfies_versor_condition` | (b) fixture + producer | Test used even-grade `_random_rotor` against grade-1 anchor (mixed parity); also needs producer guard | **Fixed test fixture** to grade-1 reflector + producer guard in #4 |
|
||||
|
||||
## Classification key (from brief)
|
||||
|
||||
- **(a)** stale committed artifact → regenerate via sanctioned generator
|
||||
- **(b)** telemetry/schema/pin drift → fix test if wrong, else producer
|
||||
- **(c)** genuinely broken capability → quarantine + ledger owner-thread
|
||||
|
||||
No **(a)** artifact regens and no **(c)** quarantines in this sweep. `QUARANTINE` remains empty.
|
||||
|
||||
## Root-cause notes
|
||||
|
||||
### INV-21 allowlist pin drift
|
||||
Canonical allowlist lives in `tests/test_architectural_invariants.py` and already includes holographic vault (ADR-0241). Two demo “unchanged” pins were stale copies.
|
||||
|
||||
### Mixed-parity `rotor_power` calls
|
||||
- Multi-token `inject` yields **even-grade** field states.
|
||||
- Single-token vault entries are often **grade-1**.
|
||||
- `word_transition_rotor(A,B) = B * reverse(A)` between different parities is a **unit odd versor**, not a rotor.
|
||||
- Historical `rotor_power` returned identity for non-simple cases (silent no-op). Exact power fail-closes; callers must not crash the cognitive path.
|
||||
- Guard matches existing `word_transition_rotor` `ValueError` continue/return pattern. **No assertion weakened; algebra fail-closed kept.**
|
||||
|
||||
## Owner-thread follow-ups (non-blocking)
|
||||
|
||||
| Thread | Why |
|
||||
|--------|-----|
|
||||
| Grade-parity policy for field vs vault entries | Soft-weighted recall currently *skips* mixed-parity hits; a future design may map grade-1 hits into even motors or store multi-token finals consistently |
|
||||
| Demo allowlist pins | Prefer importing/asserting equality against the single canonical frozenset to prevent re-drift |
|
||||
|
||||
## Hard-rule checklist
|
||||
|
||||
- [x] Never weakened an assertion to pass
|
||||
- [x] Never deleted a test
|
||||
- [x] No wrong=0 surface touched
|
||||
- [x] No lane-pin artifact regen (N/A)
|
||||
- [x] Did not edit `.github/workflows/`, `core/physics/chiral_gate.py`, or `core/physics/goldtether.py`
|
||||
|
||||
## Verification (record at ship)
|
||||
|
||||
```text
|
||||
[Verification]:
|
||||
targeted fixed reds + modules: 10 passed
|
||||
python scripts/verify_lane_shas.py: 9/9 match pinned SHAs
|
||||
uv run core test --suite smoke -q: 175 passed
|
||||
pre-fix fast lane enumerate: 5 failed / 11660 passed / 106 skipped
|
||||
post-fix: those 5 green; no quarantine entries added
|
||||
```
|
||||
|
|
@ -204,7 +204,14 @@ def _recall_state(state: FieldState, vault, top_k: int) -> tuple[FieldState, int
|
|||
# power on the rotor manifold. ``rotor_power`` stays on the manifold
|
||||
# by construction (versor_condition stays < 1e-6), unlike a linear
|
||||
# blend ``weight·V + (1-weight)·identity`` which violates closure.
|
||||
V_scaled = rotor_power(V, float(weight))
|
||||
# Mixed-parity transitions (e.g. multi-token even field ↔ grade-1
|
||||
# vault hit) are unit versors but not rotors; fractional power is
|
||||
# undefined for them. Skip the hit rather than crash or silently
|
||||
# apply identity (historical non-simple no-op).
|
||||
try:
|
||||
V_scaled = rotor_power(V, float(weight))
|
||||
except ValueError:
|
||||
continue
|
||||
current = propagate_step(current, V_scaled)
|
||||
current = FieldState(
|
||||
F=current.F,
|
||||
|
|
|
|||
|
|
@ -221,7 +221,13 @@ class SessionContext:
|
|||
R = word_transition_rotor(field_state.F, self._anchor_field)
|
||||
except ValueError:
|
||||
return field_state
|
||||
R_step = rotor_power(R, _ANCHOR_PULL_ALPHA)
|
||||
# rotor_power is defined on closed unit rotors (even grade). Mixed-parity
|
||||
# transitions (field/anchor grade mismatch) are unit versors but not
|
||||
# rotors — skip the pull rather than fail the turn.
|
||||
try:
|
||||
R_step = rotor_power(R, _ANCHOR_PULL_ALPHA)
|
||||
except ValueError:
|
||||
return field_state
|
||||
pulled_F = versor_apply(R_step, field_state.F)
|
||||
return FieldState(
|
||||
F=pulled_F,
|
||||
|
|
|
|||
|
|
@ -528,6 +528,8 @@ def test_inv21_and_inv29_allowlists_are_unchanged():
|
|||
"vault/store.py",
|
||||
"generate/proposition.py",
|
||||
"generate/realize/realize.py",
|
||||
# ADR-0241 holographic standing-wave spectrum (INV-21 allowlist expansion).
|
||||
"core/physics/holographic_vault.py",
|
||||
})
|
||||
assert ALLOWED_STATUS_TRANSITION_SITES == frozenset({"vault/store.py"})
|
||||
|
||||
|
|
|
|||
|
|
@ -378,6 +378,8 @@ def test_inv21_and_inv29_allowlists_are_unchanged():
|
|||
"vault/store.py",
|
||||
"generate/proposition.py",
|
||||
"generate/realize/realize.py",
|
||||
# ADR-0241 holographic standing-wave spectrum (INV-21 allowlist expansion).
|
||||
"core/physics/holographic_vault.py",
|
||||
})
|
||||
assert ALLOWED_STATUS_TRANSITION_SITES == frozenset({"vault/store.py"})
|
||||
|
||||
|
|
|
|||
|
|
@ -122,7 +122,11 @@ def test_session_anchor_pull_output_satisfies_versor_condition() -> None:
|
|||
session.ingest(["logos"])
|
||||
|
||||
# Build a drifted field well separated from the anchor.
|
||||
drifted = _random_rotor(seed=42)
|
||||
# Use a grade-1 word versor (same parity as inject/anchor field states).
|
||||
# An even-grade random rotor would produce a mixed-parity transition that
|
||||
# is a unit versor but not a rotor — rotor_power correctly refuses it, and
|
||||
# the pull becomes a no-op. This test exercises the real Spin-geodesic path.
|
||||
drifted = _positive_unit_reflector(seed=42)
|
||||
drifted_state = FieldState(
|
||||
F=drifted,
|
||||
node=session.state.node,
|
||||
|
|
|
|||
Loading…
Reference in a new issue