Skip to content

test(storage): Establish verdicts for the two open writer-ambiguity cases - #5467

Merged
Sinity merged 1 commit into
masterfrom
work/luna-q6
Sep 23, 2026
Merged

Sinity merged 1 commit into
masterfrom
work/luna-q6

Conversation

@Sinity

@Sinity Sinity commented Sep 23, 2026 •

Copy link
Copy Markdown
Owner

Summary

Produces per-case verdicts for the two writer cases polylogue-asp4b left unestablished. Test-only; schema closure not applicable.

Produced by a gpt-5.6-luna worker.

Why this exists

asp4b AC1 asks that "each real remaining named writer bug has a discriminating fixture." Three of its five cases were already fixed at head. Two — sibling-append and supersession — were reported UNESTABLISHED by two separate workers: neither could locate a seam.

"Nobody could find it" is absence of evidence, not evidence of absence, and closing on it is the closure-by-assertion pattern this campaign's own audit condemned. So the ask was a verdict per case: either a discriminating fixture that reproduces the defect, or an argument from the writer's construction that the case cannot occur.

Both are now answered, in opposite directions.

Sibling-append — cannot occur, by construction

thread_sessions keys each membership by (thread_id, session_id). An append therefore adds exactly one distinct child and preserves every prior membership; there is no last-writer choice for a sibling to make. Pinned by an assertion that the parent thread holds 3 rows / 3 distinct sessions after two appends, alongside the existing "no membership rebuild" check.

Supersession — real, and now pinned

A revised hook claim must leave exactly one authoritative parent per child. The fixture asserts that after revision.

Anti-vacuity executed: removing the supersession demotion left both the old and revised parents authoritative. Production code restored.

Verification

devtools verify --quick                                              ->  PASSED exit=0
devtools test test_archive_tiers_write.py test_topology_hook_authority_conflict.py
                                                                     ->  134 passed / 134

The first run of that selection failed on no such column: summary — my own regression from #5446, unrelated to this branch. Rebasing onto master with #5465 merged cleared it.

AC2-AC4 were already landed at head; the compound owner FK remains at archive_tiers_specs.py:94,642. No production change was needed.

🤖 Generated with Claude Code

https://claude.ai/code/session_01ToWqpkXotr573DiQex5vcy

Summary by CodeRabbit

  • Tests
    • Expanded automated coverage for session membership updates, verifying appended sessions remain distinct and existing memberships are preserved.
    • Added checks confirming revised hook claims are reflected in stored session links.

@chatgpt-codex-connector

chatgpt-codex-connector Bot commented Sep 23, 2026 •

Copy link
Copy Markdown

Codex Review Summary

This comment shows the latest Codex review activity on this pull request.

Review Status Commit Review trigger
📝 Code Review ✅ Completed 2026-09-23T06:05:44.855429Z eb459c9 PR opened
🔒 Security Review ✅ Completed 2026-09-23T06:07:08.332109Z eb459c9 PR opened
ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review" or "@codex security review".

Codex reacts with 👀 while any review is running, comments if it has suggestions, and reacts with 👍 once all reviews finish with no findings.

@Sinity
Sinity enabled auto-merge (squash) September 23, 2026 06:02
@coderabbitai

coderabbitai Bot commented Sep 23, 2026 •

Copy link
Copy Markdown

Review in Change Stack →

Navigate logical layers of code changes, visualize relationships, and explore their blast radius.

No actionable comments were generated in the recent review. 🎉

ℹ️ Recent review info
⚙️ Run configuration

Configuration used: Organization UI

Review profile: ASSERTIVE

Plan: Advanced

Run ID: d19185fe-9919-4e3d-8fef-62a7c94dd439

📥 Commits

Reviewing files that changed from the base of the PR and between 19b4dcb and eb459c9.

📒 Files selected for processing (2)
  • tests/unit/storage/test_archive_tiers_write.py
  • tests/unit/storage/test_topology_hook_authority_conflict.py

Included review availability: Your plan provides up to 1 included review per hour; 0 remain after this review.

📜 Recent review details
🔇 Additional comments (2)
tests/unit/storage/test_archive_tiers_write.py (1)

2877-2884: LGTM!

Also applies to: 2952-2957

tests/unit/storage/test_topology_hook_authority_conflict.py (1)

398-405: LGTM!


📝 Walkthrough

Walkthrough

Two storage tests add checks for thread membership after a sibling append and for the count of hook-authoritative links.

Changes

Thread membership

Layer / File(s) Summary
Sibling append membership
tests/unit/storage/test_archive_tiers_write.py
The test documents the append-path expectation and checks that the thread has three rows with three distinct session IDs.

Hook authority

Layer / File(s) Summary
Authoritative link count
tests/unit/storage/test_topology_hook_authority_conflict.py
The test asserts that exactly one child link uses the hook-authoritative method.

Priority: ⬇️ Low

Estimated code review effort: 1 (Trivial) | ~5 minutes

Change: Other

Merge Risk: ⚪ Minimal · up to eb459

This PR adds storage-test assertions without changing runtime code. The tests cover the stated sibling-membership and hook-supersession outcomes, and no actionable merge risk remains.

🚥 Pre-merge checks | ✅ 5
✅ Passed checks (5 passed)
Check name Status Explanation
Title check ✅ Passed The title clearly identifies a test-only change that establishes verdicts for two writer-ambiguity cases. It is concise and directly related to the pull request changes.
Description check ✅ Passed The description explains the purpose, problem, solution, verification results, test-only scope, and absence of production changes. It does not use every template heading verbatim, but it provides the …
Docstring Coverage ✅ Passed Docstring coverage is 100.00% which is sufficient. The required threshold is 80.00%. Docstring coverage is scoped to functions touched by this diff. Analyzed 2 functions across 2 files.
Linked Issues check ✅ Passed Check skipped because no linked issues were found for this pull request.
Out of Scope Changes check ✅ Passed Check skipped because no linked issues were found for this pull request.
✨ Finishing Touches
📝 Generate docstrings
  • Commit to this branch
  • Create a new PR
🧪 Generate unit tests (beta)
  • Commit to this branch
  • Create a new PR

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

A rabbit checks each thread-row count
Three sessions hop into the thread
One hook link holds the claimed edge
The tests record what storage shows
Then I nibble greens and go to bed

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

@Sinity
Sinity merged commit e6583f6 into master Sep 23, 2026
3 checks passed
@Sinity
Sinity deleted the work/luna-q6 branch September 23, 2026 06:14
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