Skip to content

Milestone Escrow - #1049

Merged
Anuoluwapo25 merged 2 commits into
bakeronchain:mainfrom
Dev-journals:Milestone-Escrow
Jul 29, 2026
Merged

Milestone Escrow#1049
Anuoluwapo25 merged 2 commits into
bakeronchain:mainfrom
Dev-journals:Milestone-Escrow

Conversation

@Dev-journals

Copy link
Copy Markdown
Contributor

Summary

Adds backend support for scholarship milestone escrow creation and release. When a scholarship_treasury.execute_proposal event occurs, the server now records the escrow on-chain and persists it in the new escrows table. Milestone approval is also wired to call release_tranche on active escrows, while existing reclaim logic remains intact.

Type of Change

  • Bug fix
  • New feature
  • Smart contract change
  • Documentation
  • Breaking change
  • Other (please describe)

Checklist

  • Tests added or updated
  • No hardcoded secrets or private keys
  • If contract change: cargo test passes
  • If frontend change: npm run typecheck passes
  • If backend change: npm test passes
  • Related issues linked (Closes #...)
  • Self-review completed
  • Code follows project style guidelines

Screenshots (if applicable)

Testing

cd server && npm test -- --runInBand src/controllers/admin-milestones.controller.test.ts src/tests/admin-milestones.test.ts

Result:

2 test suites passed
35 tests passed

Additional Notes

  • Added 028_create_escrows.sql and undo migration.
  • Extended stellar-contract.service.ts with escrow creation and tranche release helpers.
  • Added event handling in event-indexer.service.ts for proposal_executed.
  • Updated admin-milestones.controller.ts to release escrow tranches on approved milestones.

Closes #1016

@Anuoluwapo25 Kindly review and merge

@Anuoluwapo25

Copy link
Copy Markdown
Contributor

@Dev-journals it's remaining one more check

@Anuoluwapo25
Anuoluwapo25 merged commit 17ef53f into bakeronchain:main Jul 29, 2026
1 check 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.

feat: Milestone Escrow — create escrow on-chain when proposal executes

2 participants