You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Add vesting cliff support with discrete cliff_secs gate before any pro-rata accrual begins
Why this matters
vesting.rs currently implements straight-line vesting without an explicit cliff window. Many investor agreements require zero claimable amount until a cliff date (e.g. 12 months), then catch-up accrual. Add a cliff_secs parameter and enforce a hard zero claim before cliff while preserving full schedule arithmetic afterward.
Scope
Implement the requested behavior across Revora-Contracts/src/vesting.rs. The solution must preserve existing compatibility, authorization, and production safeguards.
Priority
High
Acceptance criteria
The requested behavior is implemented across Revora-Contracts/src/vesting.rs with a clear, reviewable contract.
Security, authorization, validation, and data-integrity requirements in the repository context are enforced and covered by tests.
Failure, retry, timeout, concurrency, and boundary behavior is explicit and produces safe, diagnosable outcomes where applicable.
Regression coverage includes empty, invalid, duplicate, and boundary inputs relevant to this flow.
Existing API, storage, and deployment compatibility is preserved unless a migration is explicitly documented.
Validation
Include focused tests for:
happy paths;
invalid input and authorization boundaries;
concurrency, retries, or failure recovery;
backward compatibility;
relevant integration or contract behavior.
The implementation must pass the repository’s existing build, lint, test, and formatting checks (use cargo test --all where applicable).
Non-goals
Typo-only, formatting-only, or documentation-only changes.
Unrelated refactors or dependency upgrades.
Weakening security, authorization, CI, or production safeguards.
Changing public behavior outside this issue’s scope.
Contributor application
Before implementation, comment with:
relevant experience;
a concise implementation approach;
expected files or modules affected;
an estimate for opening the first PR.
Wait for maintainer assignment before coding.
PR requirements
Use a feature branch and include Closes #.
The PR must:
address every acceptance criterion;
link each criterion to code and tests;
explain security and failure-mode handling;
include meaningful regression coverage;
document compatibility or migration considerations;
pass the repository checks.
Reward-readiness
This is a substantive quality issue. Merge status does not guarantee reward eligibility; final evaluation is determined separately.
Implementation context
Description
vesting.rs currently implements straight-line vesting without an explicit cliff window. Many investor agreements require zero claimable amount until a cliff date (e.g. 12 months), then catch-up accrual. Add a cliff_secs parameter and enforce a hard zero claim before cliff while preserving full schedule arithmetic afterward.
Requirements and context
Must be secure, tested, and documented
Should be efficient and easy to review
Relevant code: Revora-Contracts/src/vesting.rs
Pre-cliff claim attempts must emit a typed VestingCliffNotReached error, not silently return zero
Suggested execution
Fork the repo and create a branch
git checkout -b feat/vesting-cliff-secs
Implement changes
Add cliff_secs: u64 to VestingSchedule
Gate claim_vested and vested_amount_at on now >= start + cliff_secs
Document interaction with vesting amendment under VESTING_AMENDMENT_IMPLEMENTATION.md
Validate security and correctness assumptions
Test and commit
Run tests
cargo test --all
Cover edge cases
now == start + cliff_secs exactly should release the full pre-cliff accrual
Include test output and security notes
Example commit message
feat: enforce vesting cliff_secs gate before pro-rata accrual
Summary
Add vesting cliff support with discrete cliff_secs gate before any pro-rata accrual begins
Why this matters
vesting.rscurrently implements straight-line vesting without an explicit cliff window. Many investor agreements require zero claimable amount until a cliff date (e.g. 12 months), then catch-up accrual. Add acliff_secsparameter and enforce a hard zero claim before cliff while preserving full schedule arithmetic afterward.Scope
Implement the requested behavior across Revora-Contracts/src/vesting.rs. The solution must preserve existing compatibility, authorization, and production safeguards.
Priority
High
Acceptance criteria
Validation
Include focused tests for:
The implementation must pass the repository’s existing build, lint, test, and formatting checks (use cargo test --all where applicable).
Non-goals
Contributor application
Before implementation, comment with:
Wait for maintainer assignment before coding.
PR requirements
Use a feature branch and include Closes #.
The PR must:
Reward-readiness
This is a substantive quality issue. Merge status does not guarantee reward eligibility; final evaluation is determined separately.
Implementation context
Description
vesting.rscurrently implements straight-line vesting without an explicit cliff window. Many investor agreements require zero claimable amount until a cliff date (e.g. 12 months), then catch-up accrual. Add acliff_secsparameter and enforce a hard zero claim before cliff while preserving full schedule arithmetic afterward.Requirements and context
Revora-Contracts/src/vesting.rsVestingCliffNotReachederror, not silently return zeroSuggested execution
git checkout -b feat/vesting-cliff-secscliff_secs: u64toVestingScheduleclaim_vestedandvested_amount_atonnow >= start + cliff_secsTest and commit
cargo test --allExample commit message
feat: enforce vesting cliff_secs gate before pro-rata accrualGuidelines