[N-02] Allowance Audit#425
Conversation
… execution status
|
Important Review skippedAuto incremental reviews are disabled on this repository. Please check the settings in the CodeRabbit UI or the ⚙️ Run configurationConfiguration used: Organization UI Review profile: CHILL Plan: Pro Run ID: You can disable this status message by setting the Use the checkbox below for a quick retry:
WalkthroughThis PR updates documentation comments only, within three public functions (spend, withdraw, withdraw_all) in spend_vault.move. The Aborts sections now describe EObjectFundsWithdrawNotEnabled as a framework Move #[error] abort (code 3 in sui::funds_accumulator) instead of generic execution-status wording. No code logic changes. ChangesAbort doc updates
Estimated code review effort🎯 1 (Trivial) | ⏱️ ~3 minutes Poem
🚥 Pre-merge checks | ✅ 4 | ❌ 1❌ Failed checks (1 warning)
✅ Passed checks (4 passed)
✨ Finishing Touches🧪 Generate unit tests (beta)
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
There was a problem hiding this comment.
🧹 Nitpick comments (1)
contracts/allowance/sources/spend_vault.move (1)
1149-1151: 📐 Maintainability & Code Quality | 🔵 Trivial | 💤 Low valueName the propagation source explicitly for consistency with
spend.
spenddocuments this same abort as "propagated fromwithdraw_funds_from_object" (line 809). Consider aligningwithdrawto name the primitive explicitly — the call is at line 1167 and integrators benefit from knowing the exact propagation path./// - `EObjectFundsWithdrawNotEnabled` if the `enable_object_funds_withdraw` /// protocol feature is off: a framework Move `#[error]` abort (code 3 in -/// `sui::funds_accumulator`). +/// `sui::funds_accumulator`) propagated from `withdraw_funds_from_object`.🤖 Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the rest with a brief reason, keep changes minimal, and validate. In `@contracts/allowance/sources/spend_vault.move` around lines 1149 - 1151, Update the `withdraw` documentation in `spend_vault.move` to explicitly state that `EObjectFundsWithdrawNotEnabled` is propagated from `withdraw_funds_from_object`, matching the wording used by `spend` for consistency. Keep the existing abort condition, but revise the comment near `withdraw` to name the underlying primitive clearly so integrators can trace the propagation path; use the `withdraw` and `withdraw_funds_from_object` symbols to locate the relevant doc text.Source: Path instructions
🤖 Prompt for all review comments with AI agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.
Nitpick comments:
In `@contracts/allowance/sources/spend_vault.move`:
- Around line 1149-1151: Update the `withdraw` documentation in
`spend_vault.move` to explicitly state that `EObjectFundsWithdrawNotEnabled` is
propagated from `withdraw_funds_from_object`, matching the wording used by
`spend` for consistency. Keep the existing abort condition, but revise the
comment near `withdraw` to name the underlying primitive clearly so integrators
can trace the propagation path; use the `withdraw` and
`withdraw_funds_from_object` symbols to locate the relevant doc text.
ℹ️ Review info
⚙️ Run configuration
Configuration used: Path: .coderabbit.yaml
Review profile: CHILL
Plan: Pro
Run ID: e86fdb0c-7d5a-48b1-9c12-c95ed842e000
📒 Files selected for processing (1)
contracts/allowance/sources/spend_vault.move
Codecov Report✅ All modified and coverable lines are covered by tests. Additional details and impacted files@@ Coverage Diff @@
## main #425 +/- ##
==========================================
- Coverage 96.54% 96.51% -0.04%
==========================================
Files 32 32
Lines 3324 3324
Branches 784 783 -1
==========================================
- Hits 3209 3208 -1
Misses 70 70
- Partials 45 46 +1
Flags with carried forward coverage won't be shown. Click here to find out more. ☔ View full report in Codecov by Harness. 🚀 New features to boost your workflow:
|
Fixes N-02
Summary by CodeRabbit