Skip to content

BE-49: Reconcile Soroban escrow state with payment records - #832

Merged
Qoder-Voidd merged 3 commits into
Akazajan:mainfrom
harmondconsultant-png:fix/634-escrow-reconcile
Oct 25, 2026
Merged

Qoder-Voidd merged 3 commits into
Akazajan:mainfrom
harmondconsultant-png:fix/634-escrow-reconcile

Conversation

@harmondconsultant-png

@harmondconsultant-png harmondconsultant-png commented Oct 23, 2026 •

Copy link
Copy Markdown

Closes #634

  • Adds normalized escrow outcomes (pending, confirmed, failed, timed_out) with final/retryable flags.
  • reconcileEscrow treats transient RPC failures as retryable pending, never final settlement.
  • Adds escrowStatus / escrowReconciledAt columns to Payment.
  • Unit tests in the provider spec; also corrected two pre-existing wrong hash expectations in that spec (soroban_release_stub_ / soroban_refund_stub_).

Verification (Node 20):

  • jest soroban-escrow.provider.spec.ts: 11/11 pass.
  • jest src/payments overall: other suites fail on pre-existing syntax/duplicate-identifier errors elsewhere in the repo (auth.service.ts, bookings.service.ts, refund-payment.provider.ts); not caused by this PR.
  • Full tsc fails only on those same pre-existing files; no errors in the files changed here.
  • eslint: only CRLF/prettier noise from the Windows checkout plus pre-existing formatting in payment.entity.ts.

Scope note: the issue limits changes to three files, so reconcileEscrow is not yet wired into handle-webhook.provider.ts and no migration is added (migrations dir has no schema-sync convention for payments). Follow-up needed for both.

🤖 Generated with Claude Code

Dayz-tech-co and others added 3 commits October 23, 2026 23:40
…s (BE-49)

Add normalized pending/confirmed/failed/timed_out escrow outcomes, treat
transient RPC failures as retryable and non-final, and persist escrow
status on Payment.

Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>

@Qoder-Voidd Qoder-Voidd left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

@Qoder-Voidd
Qoder-Voidd merged commit 34745ef into Akazajan:main Oct 25, 2026
1 of 7 checks passed
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.

BE-49 — Reconcile Soroban escrow state with payment records

3 participants