Skip to content

fix(replay): preflight material occurrence coordinates - #2622

Open
Sinity wants to merge 1 commit into
masterfrom
fix/replay-coordinate-preflight
Open

fix(replay): preflight material occurrence coordinates#2622
Sinity wants to merge 1 commit into
masterfrom
fix/replay-coordinate-preflight

Conversation

@Sinity

@Sinity Sinity commented Aug 15, 2026

Copy link
Copy Markdown
Owner

Summary

  • add a whole-context replay preflight before CAS initialization or record processing
  • reject non-byte coordinates, missing or invalid byte ranges, and missing material occurrences
  • add regression coverage for non-byte and incomplete replay envelopes

Problem

Scoped replay is CAS-authoritative for byte-ranged occurrences, but malformed or native non-byte occurrence coordinates could be discovered only after replay work had begun. That leaves an unsafe boundary around archive/partial processing and does not provide a reusable fail-closed preflight.

Solution

validate_material_replay_context validates every selected material and occurrence before the CAS route opens, reads, parses, or emits. The existing per-material checks remain in place to validate each range against the authoritative CAS length.

Verification

  • SINEX_TEST_TMPDIR=/realm/project/sinex/.sinex/test-tmp xtask test -p sinexd -E 'test(/replay_context_preflight_rejects_(non_byte|missing)_coordinates_before_work/)' --impact-mode=off — invocation 2007874, 2 passed.
  • xtask check --changed-strict origin/master — pre-push invocation, 1 package (sinexd) passed.
  • git diff --cached --check — passed.

Residual scope: native replay implementations for non-byte adapters and coordinator-side archive ordering remain tracked by sinex-nbag; this change fails closed at the source replay boundary and does not claim that bead closed.

@chatgpt-codex-connector

Copy link
Copy Markdown

You have reached your Codex usage limits for code reviews. You can see your limits in the Codex usage dashboard.
To continue using code reviews, add credits to your account and enable them for code reviews in your settings.

@coderabbitai

coderabbitai Bot commented Aug 15, 2026

Copy link
Copy Markdown

Important

Review available on request

  • 🔍 Trigger review

Reviews should be triggered manually for repositories with fewer than 10 stars. Select Trigger review above or comment @coderabbitai review to review the latest changes. For a full review, comment @coderabbitai full review.

⚙️ Run configuration

Configuration used: Path: .coderabbit.yaml

Review profile: ASSERTIVE

Plan: Pro Plus

Run ID: 0000cbc5-938f-4a7f-9076-e81f0a9debb1


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.

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