Skip to content

MilestonesService.resolveIssue's incremental-release model has no counterpart in the real mergefi-milestones contract #162

Closed

Description

@chonilius

MilestonesService.resolveIssue() distributes a milestone's budget by repeatedly calling EscrowService.releasePartial() against one Escrow row that was fund()-ed once for the milestone's full budget and stays LOCKED across many partial releases (one per resolved issue).

The real mergefi-milestones contract (MergeFi/contracts, contracts/milestones/src/lib.rs) models this completely differently: create_milestone() opens a budget pool, allocate(milestone_id, issue_id, amount) reserves a slice of the unallocated remainder for one specific issue_id (admin-only, rejects over-allocation), and release_issue(milestone_id, issue_id, recipients) pays out that specific issue's already-reserved slice. There is no "partially release from a locked escrow" primitive at all — resolveIssue's even-split-of-remainingBudget-across-openIssues logic, and its single ever-LOCKED Escrow row, don't correspond to anything the real contract exposes. Making milestones work against the real contract needs MilestonesService to track per-issue allocations (mirroring allocate/release_issue) rather than one shared escrow drained via repeated partial releases — a data-model change in this service, not just an argument-encoding fix in SorobanClientService.

Activity

  1. added
    architectureArchitecture/design issue
    securitySecurity-related issue
    very hardVery difficult task, expert-level effort required
    help wantedExtra attention is needed
    on Aug 21, 2026
  2. Syringe7 commented on Aug 21, 2026

    @Syringe7

    I would love to work on this issue. please assign to me to work on it ASAP

  3. Syringe7 commented on Aug 21, 2026

    @Syringe7

    I would love to work on this issue. please assign to me to work on it ASAP

  4. codefather2026 commented on Aug 26, 2026

    @codefather2026

    @codefather2026 has applied to work on this issue as part of the Stellar Wave Program's 8th wave.

    Hi maintainer, i will like to solve this issue

    ℹ️ Repo Maintainers: To accept this application, review their application or assign @codefather2026 to this issue.

  5. rubbathabrahband commented on Aug 26, 2026

    @rubbathabrahband

    @bade22brazy has applied to work on this issue as part of the Stellar Wave Program's 8th wave.

    hello maintainer, kindly assign these issues to me. i am sure of handling thenm after careful and thorough review

    ℹ️ Repo Maintainers: To accept this application, review their application or assign @bade22brazy to this issue.

  6. drips-wave commented on Aug 26, 2026

    @drips-wave

    Congratulations, @bade22brazy! 🎉 Your application was accepted by the repo's maintainers, and the issue is due on August 31, 2026.

    🧑‍💻 @bade22brazy: Please resolve the issue such that the repo's maintainers have enough time to review your contribution before the due date. You'll earn Points for completing the issue on-time, which will make you eligible for a share of the Stellar Wave Program's reward pool.

    Warning

    When opening a PR, please link it to this issue to ensure it gets tracked accurately. Points are awarded when this issue is marked as completed by the maintainer.

    🤠 Repo maintainers: Please keep an eye on the contributor's progress and review their work before the due date. You can manage this issue, including adjusting its complexity and points, here.

    🌊 Happy Wave 🌊

  7. added a commit that references this issue on Aug 26, 2026
  8. drips-wave commented on Aug 26, 2026

    @drips-wave

    This issue has been completed by @bade22brazy as part of the Stellar Wave Program's 8th Wave 🥳

    😎 @bade22brazy: You earned 200 Points for completing this issue! After the current Wave ends, you'll be eligible for a percentage of the Wave's reward pool based on the percentage of total points you've earned. Learn more here. You can also Leave a review to share your experience working on this issue.

    🧑‍💻 Repo maintainers: How'd the contributor do? Leave a review to share your experience working with them.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Labels

Stellar WaveIssues in the Stellar wave programarchitectureArchitecture/design issuehelp wantedExtra attention is neededsecuritySecurity-related issuevery hardVery difficult task, expert-level effort required

Type

No type

Projects

No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions