Skip to content

Feature/contracts 21 escrow fee model support#141

Merged
mikewheeleer merged 28 commits intoTalenttrust:mainfrom
gloskull:feature/contracts-21-escrow-fee-model-support
Apr 1, 2026
Merged

Feature/contracts 21 escrow fee model support#141
mikewheeleer merged 28 commits intoTalenttrust:mainfrom
gloskull:feature/contracts-21-escrow-fee-model-support

Conversation

@gloskull
Copy link
Copy Markdown
Contributor

@gloskull gloskull commented Mar 25, 2026

Closes #71


Pull Request: feat/contracts-21-escrow-fee-model-support

Summary

  • Implemented configurable protocol fee accounting per milestone release in contracts/escrow/src/lib.rs.
  • Added contract-level fields:
    • protocol_fee_bps (basis points, 0-10000)
    • protocol_fee_account
    • protocol_fee_accrued
  • Added milestone-level field:
    • protocol_fee
  • Added methods:
    • get_protocol_fee_accrued
    • withdraw_protocol_fees
    • set_protocol_fee_bps
  • Extended create_contract signature to accept fee model parameters.
  • Added fee model behavior to release_milestone.

Tests

  • Updated existing tests to pass new API args.
  • Added new tests:
    • test_release_milestone_protocol_fee_accrual
    • test_withdraw_protocol_fees
    • test_withdraw_protocol_fees_unauthorized
    • test_set_protocol_fee_bps_invalid
  • cargo test passes (24 passed).

Attachment (Proof-of-build)
Screenshot from 2026-03-25 11-45-22

@drips-wave
Copy link
Copy Markdown

drips-wave bot commented Mar 25, 2026

@gloskull 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! 🚀

Learn more about application limits

@mikewheeleer
Copy link
Copy Markdown
Contributor

please resolve the conflicts

@gloskull
Copy link
Copy Markdown
Contributor Author

@mikewheeleer please merge

1 similar comment
@gloskull
Copy link
Copy Markdown
Contributor Author

@mikewheeleer please merge

@mikewheeleer mikewheeleer merged commit 1280477 into Talenttrust:main Apr 1, 2026
1 check failed
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.

[Mike] 21. Escrow fee model support

2 participants