Skip to content

fix(storage): resolve whale stream safety for expanded members (#3268) - #3268

Merged
Sinity merged 1 commit into
masterfrom
fix/storage/whale-pass-stream-safety-expanded-members
Jul 22, 2026
Merged

Sinity merged 1 commit into
masterfrom
fix/storage/whale-pass-stream-safety-expanded-members

Conversation

@Sinity

@Sinity Sinity commented Jul 22, 2026

Copy link
Copy Markdown
Owner

Summary

Allow the daemon whale pass to recognize stream-safe authority components when some expanded members have already materialized.

Problem

The live 6.33 GiB Codex witness component was rejected by the whale-pass eligibility check even though its members are stream-safe. The check consulted candidate-only identity maps, so already-materialized members resolved as unknown and made the component appear unsafe.

Solution

polylogue/storage/repair.py now records origin and source path for every expanded authority-component member and falls back to those maps during stream-safety evaluation. The focused regression test exercises a member present only in the expanded maps.

Ref polylogue-t93b.

Verification

  • devtools test tests/unit/storage/test_repair.py -k 'stream_safe or whale_pass_candidate' — 3 passed.
  • uv run mypy --strict polylogue/storage/repair.py — Success: no issues found.
  • devtools verify --quick — completed successfully.
  • Pre-push quick baseline — format, lint, mypy, rendering, topology, layering, schema roundtrip, manifests, CI workflow, documentation, and test-infrastructure gates passed.

Acceptance criteria

  • Satisfied: the live whale component is no longer incorrectly excluded because an expanded, already-materialized member lacks candidate-map identity.
  • Remaining polylogue-t93b scope: daemon deployment must converge the live witness and emit its receipt.

The daemon's escalation-tier whale pass skipped a stream-safe Codex component
because members already materialized from that component were absent from the
candidate-only origin and source-path maps. They were consequently treated as
unknown and rendered the whole component ineligible for streaming replay.

Carry identity metadata for every expanded component member and consult it as a
fallback when assessing stream safety. The regression test exercises a
non-candidate member that is present only in the expanded maps.

Ref polylogue-t93b.

Co-Authored-By: Codex <[email protected]>
@coderabbitai

coderabbitai Bot commented Jul 22, 2026

Copy link
Copy Markdown

Warning

Review limit reached

@Sinity, you've reached your PR review limit, so we couldn't start this review.

Next review available in: 34 minutes

Enable usage-based reviews in Billing to review now. Otherwise, wait until the next included review is available.
You're only billed for reviews past your plan's rate limits ($0.25/file).

How can I continue?

After more reviews become available, a review can be triggered using the @coderabbitai review command as a PR comment. Alternatively, push new commits to this PR.

To avoid repeated limits, reduce automatic review volume by pausing incremental auto-reviews earlier, using label-based review opt-in, excluding WIP or generated PR titles, or requesting reviews manually when the PR is ready. If your team needs uninterrupted high-volume reviews, an organization admin can enable usage-based reviews.

How do review limits work?

CodeRabbit enforces per-developer PR review limits for each organization. Most developers receive the normal plan review availability.

For paid Pro and Pro+ PR reviews, CodeRabbit uses adaptive limits for sustained high-volume activity. When a developer's recent PR review activity reaches the 95th percentile or higher among CodeRabbit users, additional reviews become available more gradually as earlier reviews age out of the rolling window.

Please refer docs for additional details.

Review details
⚙️ Run configuration

Configuration used: Path: .coderabbit.yaml

Review profile: ASSERTIVE

Plan: Pro

Run ID: 60b0eed6-bbdd-492e-a4b9-35047627d02d

📥 Commits

Reviewing files that changed from the base of the PR and between b365768 and 05e7519.

📒 Files selected for processing (2)
  • polylogue/storage/repair.py
  • tests/unit/storage/test_repair.py
✨ Finishing Touches
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Commit unit tests in branch fix/storage/whale-pass-stream-safety-expanded-members

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands.

@Sinity Sinity changed the title fix(storage): resolve whale stream safety for expanded members fix(storage): resolve whale stream safety for expanded members (#3268) Jul 22, 2026
@Sinity
Sinity merged commit d6caf83 into master Jul 22, 2026
3 checks passed
@Sinity
Sinity deleted the fix/storage/whale-pass-stream-safety-expanded-members branch July 22, 2026 18:47
Sinity added a commit that referenced this pull request Aug 2, 2026
Problem: polylogue-t93b (daemon must converge whale raw components)
was dispatched for implementation, but the escalation-tier whale pass
was already fully implemented and merged (#3256, #3268, #3455, #3489)
prior to this session, per a same-day RECONCILE note already on the
bead.

What changed: independently re-verified the mechanism from source
(daemon/cli.py _maybe_run_raw_materialization_whale_pass,
storage/repair.py raw_materialization_whale_pass_candidate +
stream-safe gating), ran the relevant tests (test_repair.py -k
whale_pass, test_daemon_cli.py -k whale — 8 passed, covering the
synthetic-fixture convergence AC, the non-stream-safe-fails-safely AC,
and the bounded-commit-batch AC), and checked the live archive
read-only for witness codex:019f49d8's current state. Appended a
confirmation note: mechanism is done, witness has not converged yet
purely because the ordinary trickle conveyor has not reached
quiescence (whale pass only fires when quiescent), not because of a
code gap.

No production code changed. No PR opened — there was nothing to
change.

Co-Authored-By: Claude <[email protected]>
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