HcbCodes with duplicate CanonicalPendingTransactions
- Dominant language
- Ruby
- Stars
- 870
- Forks
- 138
- Avg merge
- 1d 14h
- Merged PRs (30d)
- 208
Description
Three things:
1. Figure out why we're creating duplicate CPTs for a single BankFee HcbCode (`HCB-700-%`)
2. Figure out why we're creating duplicate CPTs for a single card charge HcbCode (`HCB-600-%`)
3. Add an index on `transaction_source_type` `transaction_source_id` to prevent this
- https://hcb.hackclub.com/blazer/queries/810-hcbcodes-with-duplicate-canonicalpendingtransactions
- https://hackclub.slack.com/archives/C026RKHLPNJ/p1739411987092909
- https://hcb.hackclub.com/blazer/queries/808-duplicate-cpts-for-a-single-rawpendingstripetransaction
Contributor guide
Research direction
Start with Blazer queries 810 and 808, then review the linked Slack discussion to trace how duplicate CanonicalPendingTransactions arise for HCB-700-% and HCB-600-%. Done means both duplicate paths are understood and an index covering transaction_source_type and transaction_source_id prevents duplicate records.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- ruby
- Domain
- backend, databases
- Issue type
- Bug
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 42/100