Skip to content

Return Base Reserve on Expiration #29

@phertyameen

Description

@phertyameen

Goal

Ensure reserve is returned when account expires.

Problem

Expiration logic does not currently include reserve return.

Scope

Expiration Flow

  • Include stored reserve in returned funds.
  • Transfer to recovery address.
  • Mark reserve as reclaimed or clear storage.

Safety

  • Prevent double-return.
  • Handle zero-balance edge cases.

Acceptance Criteria

  • Expiration returns payment funds + reserve.
  • Storage cleared appropriately.
  • Tests cover expiration scenario.

⚠️ Contributor Note

This change affects account lifecycle and balance safety.

Please:

  • Avoid implementing based solely on AI-generated patterns.
  • Verify Stellar/Soroban minimum balance requirements independently.
  • Ensure correct stroop calculations and edge-case handling.
  • Confirm no invariant violations or unintended balance locks occur.
  • Incorrect reserve handling can permanently lock funds.

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions