Repository navigation
Restore global request_id uniqueness and missing usage event columns - #1543
Merged
Merged
Conversation
|
@Joseph-tech10 Great news! 🎉 Based on an automated assessment of this PR, the linked Wave issue(s) no longer count against your application limits. You can now already apply to more issues while waiting for a review of this PR. Keep up the great work! 🚀 |
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> # Conflicts: # src/services/billing.ts # src/services/usageStore.ts
greatest0fallt1me
added a commit
that referenced
this pull request
Oct 24, 2026
- Revert #1543 (global request ID registry). It was merged without CI running, broke ten suites that build pg-mem/mock schemas without apis/usage_event_request_ids, and its own integration test failed. Its migration was added today and is removed; revenue_ledger_indexer moves to 0032. - idempotencySweeper test: drop duplicate __filename/import.meta use that cannot compile under CommonJS jest. - revenueLedgerIndexer test: give mocked events a stellarTxHash now that only confirmed charges are indexed, wait for the first query before releasing it, and use TIMESTAMPTZ for the pg-mem lease column. - reportExporter test: the CSV stream ends with a newline. - settlementStoreSchema test: settlement amounts are bigint units. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
greatest0fallt1me
added a commit
that referenced
this pull request
Oct 24, 2026
* fix: repair corrupted code merged in #1525, #1538, #1539 and #1540 Restore identifiers and values mutated by corrupted merges and get the migration layout policy passing again. - config: restore TESTNET_NETWORK_PASSPHRASE ("Test SDF Network ; September 2015"), drop references to undefined env keys - env: restore DB_POOL_MAX / DB_IDLE_TIMEOUT_MS / DB_CONN_TIMEOUT_MS / DB_USER, drop duplicate STELLAR_*_HORIZON_URL / *_VAULT_CONTRACT_ID keys, restore safeParse error reporting - feeBumper: revert the unwired, broken rewrite from #1539 - revert #1540 (mutated metrics test identifiers, NUL byte in a test, deleted tests, conflict branch with no service support) - migrations: drop the never-runnable 0026_add_developer_payout_address (syntax error, unused) and the unused fee/fingerprint migrations; renumber the remaining duplicate 0026/0027 files sequentially in merge order; add missing rollback/destructive-approved markers - services/billing: import logger; routes/billing: narrow repo type - docs: restore mutated contract ids in network-configuration.md Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> * fix: revert #1543 and repair tests broken by unverified merges - Revert #1543 (global request ID registry). It was merged without CI running, broke ten suites that build pg-mem/mock schemas without apis/usage_event_request_ids, and its own integration test failed. Its migration was added today and is removed; revenue_ledger_indexer moves to 0032. - idempotencySweeper test: drop duplicate __filename/import.meta use that cannot compile under CommonJS jest. - revenueLedgerIndexer test: give mocked events a stellarTxHash now that only confirmed charges are indexed, wait for the first query before releasing it, and use TIMESTAMPTZ for the pg-mem lease column. - reportExporter test: the CSV stream ends with a newline. - settlementStoreSchema test: settlement amounts are bigint units. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> * fix: make revenue ledger SQL and test schemas work under pg-mem - indexRevenueLedgerEvent: use uncorrelated EXISTS/NOT EXISTS guards (same semantics) instead of selecting from usage_events in the insert. - Lease fallback (used only without advisory locks): take a free lease with a guarded UPDATE, else create the row with ON CONFLICT DO NOTHING, instead of ON CONFLICT DO UPDATE ... WHERE. - pg-mem harnesses: TIMESTAMPTZ for lease/retry columns compared to NOW(). - billing.units test schema: add deduction_status columns. - idempotencySweeper test: wait for the second postgres ready message. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> * test: run revenue ledger indexer DB tests on real PostgreSQL The indexer SQL from #1544 uses features pg-mem cannot emulate, so the database-backed indexer tests now use a testcontainers PostgreSQL (one database per harness). The pg-mem copy of the findUnindexed test is skipped with a pointer to that coverage. Make the sweeper time-budget test deterministic by driving performance.now(). Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> --------- Co-authored-by: greatest0fallt1me <greatest0fallt1me@users.noreply.github.com> Co-authored-by: Claude Opus 5.5 <noreply@anthropic.com>
5 tasks
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Verification
git diff --checkpassed.EXPLAINchecks were not run because dependencies and a local database are unavailable in this environment.Closes #1486