Skip to content

fix(db): retain quarantine replay replacements during pruning - #591

Merged
imshashank merged 3 commits into
mainfrom
codex/fix-prune-quarantine-references
Nov 16, 2026
Merged

imshashank merged 3 commits into
mainfrom
codex/fix-prune-quarantine-references

Conversation

@imshashank

@imshashank imshashank commented Nov 16, 2026 •

Copy link
Copy Markdown
Contributor

Operational pruning could fail when an expired webhook delivery was still referenced as a quarantine replay replacement. The delete now preserves those referenced deliveries while continuing to remove unrelated expired rows.

The change is limited to the retention predicate and its regression test. No migration is required.

Validation:

  • Focused prune tests: reproduced the FK failure before the fix, then 10 passed after the fix.
  • Full verification at 4b1260b6ab6b51a5081e22b8016015f8ebe1ac95: 7,149 passed, 0 failed, 0 skipped, with all static and type checks green.
  • The full run used a clean checkout and eight dedicated local databases with exact runtime, OID, ledger and actual package child guards. Source remained unchanged.
  • Fresh exact-head CI (all six jobs), CodeQL, links, documentation, recovery checks and preview passed.

The branch includes current main b00577e26b3feb1f456ebd888de60d37b6c7d64f.

@coderabbitai

coderabbitai Bot commented Nov 16, 2026 •

Copy link
Copy Markdown

Warning

Review limit reached

You've used all free OSS reviews for now. Wait for the free limit to reset to keep reviewing this public repository.

Next included review available in 11 minutes.

Check out review usage here.

View limit details

Limit details: You’ve used the included review currently available.

Learn how review limits work.

Review configuration:

Run configuration

  • Source mode: Auto
  • Repository: Noveum/orbit
  • Branch: main
  • File: .coderabbit.yaml
  • Commit: b00577e
  • Layers: Repository YAML
  • Review profile: CHILL
  • Plan: Advanced
  • Run ID: 598bad15-93c7-4941-bf69-ce45680a3f2c
Commits

Reviewing files that changed from the base of the PR and between b00577e and 4b1260b.

Files selected for processing: 2

  • packages/db/src/prune.ts
  • packages/db/tests/prune.test.ts
  • Autofix · Keep fixing CodeRabbit findings and required CI, and resolving merge conflicts

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

@github-actions github-actions Bot added tests Test coverage and test infrastructure area: database Schema, migrations, queries, seed labels Nov 16, 2026
@imshashank
imshashank marked this pull request as ready for review November 16, 2026 22:06
@imshashank
imshashank requested a review from pulkitxm as a code owner November 16, 2026 22:06
@vercel

vercel Bot commented Nov 16, 2026 •

Copy link
Copy Markdown

The latest updates on your projects. Learn more about Vercel for GitHub.

Project Deployment Actions Updated
orbit Ready Ready Preview Nov 16, 2026 10:20pm UTC

Request Review

@imshashank
imshashank merged commit 9113ce7 into main Nov 16, 2026
19 checks passed
@imshashank
imshashank deleted the codex/fix-prune-quarantine-references branch November 16, 2026 22:21

This branch was successfully deployed

1 active deployment
Preview — 4b1260b6 Deployed Nov 16, 2026 by vercel[bot]
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

area: database Schema, migrations, queries, seed tests Test coverage and test infrastructure

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant