Simplify dormant checkout stage cleanup - #1848
Conversation
|
No actionable comments were generated in the recent review. 🎉 ℹ️ Recent review info⚙️ Run configurationConfiguration used: Organization UI Review profile: ASSERTIVE Plan: Pro Plus Run ID: 📒 Files selected for processing (1)
📝 WalkthroughWalkthroughCheckout-stage rows are added to attendee deletion, orphan purging, and attendee merging cleanup paths. Checkout-stage revision tables and triggers are removed from the schema and deleted through a registered migration, with updated migration and integration tests. ChangesCheckout stage cleanup
Estimated code review effort: 3 (Moderate) | ~25 minutes Sequence Diagram(s)sequenceDiagram
participant AttendeeOperation
participant DependentDeleteSQL
participant CheckoutStages
AttendeeOperation->>DependentDeleteSQL: build deletion for attendee IDs
DependentDeleteSQL->>CheckoutStages: delete matching checkout-stage rows
CheckoutStages-->>AttendeeOperation: cleanup completes
Possibly related PRs
🚥 Pre-merge checks | ✅ 5✅ Passed checks (5 passed)
✨ Finishing Touches📝 Generate docstrings
🧪 Generate unit tests (beta)
Comment |
There was a problem hiding this comment.
Actionable comments posted: 1
🤖 Prompt for all review comments with AI agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.
Inline comments:
In `@test/shared/db/orphan-attendees.test.ts`:
- Around line 155-161: Update the childCount helper used by the “removes the
orphan's checkout stage” test to require that the COUNT(*) query returns an
aggregate row, rather than converting a missing row to 0. Keep returning the
row’s count for valid results so the assertion remains capable of detecting the
checkout-stage deletion.
🪄 Autofix (Beta)
Fix all unresolved CodeRabbit comments on this PR:
- Push a commit to this branch (recommended)
- Create a new PR with the fixes
ℹ️ Review info
⚙️ Run configuration
Configuration used: Organization UI
Review profile: ASSERTIVE
Plan: Pro Plus
Run ID: a45fb58a-f899-433a-acd4-75d71b84a536
📒 Files selected for processing (15)
src/shared/db/attendees/delete.tssrc/shared/db/migrations/2026-07-15_checkout_stages.tssrc/shared/db/migrations/2026-07-16_drop_checkout_stage_revisions.tssrc/shared/db/migrations/registry.tssrc/shared/db/migrations/schema/checkout-stage-triggers.tssrc/shared/db/migrations/schema/tables-attendees.tssrc/shared/db/migrations/schema/triggers.tssrc/shared/merge/attendee-merge.tstest/lib/db/attendees/delete-attendee.test.tstest/lib/db/checkout-stage-schema.test.tstest/lib/db/migration-restore/verify.test.tstest/lib/db/migration-schema-guard.test.tstest/shared/db/orphan-attendees.test.tstest/shared/merge/attendee-merge/checkout-stage-cleanup.test.tstest/test-utils/checkout-stages.ts
💤 Files with no reviewable changes (3)
- src/shared/db/migrations/schema/checkout-stage-triggers.ts
- src/shared/db/migrations/schema/tables-attendees.ts
- src/shared/db/migrations/schema/triggers.ts
What changed
Checkout and payment runtime remain disabled. Open checkout stages are temporary and do not need to survive deploys, host moves, restores, attendee deletion, or attendee merges. This change does not alter backup, export, or restore behavior.
Checks
nix develop -c deno task precommitpasses.nix develop -c deno task precommit:mutationpasses with 541 of 541 detectable mutants killed.Summary by CodeRabbit