Repository navigation
feat(wallet): scheduled payments - #43
Merged
Merged
Conversation
A member schedules payments to repeat (weekly to yearly, from a first date, approved by the members they pick). The schedule travels in the group's records, so every member sees it, its next date and when it was last sent; only its author can stop it. On each date the author's app asks the approvers through wallet_send, like any other payment, so the approvers' checks, the group's rules and automatic approval within a spending limit apply unchanged. Each date is asked once; a payment more than 3 days late is skipped and shown as missed. Months are counted on the calendar, falling back to the month's last day. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Groups can now schedule payments that repeat, such as payroll, rent or subscriptions. Each one is still approved like any other payment. Stacked on #42 (share repair).
wallet_send. Each approver's checks, the group's rules and automatic approval within a spending limit all apply unchanged. With a limit, trusted payees and auto-approving members, a schedule pays without anyone clicking.How it works
Schedule,ScheduleStoppedandScheduleRun, incore/src/polls.rs. Older versions keep and skip them.core/src/schedules.rsworks out each schedule:commands/schedules.rsaddslist_schedules,due_schedules,create_schedule,stop_scheduleandrecord_schedule_run.commands::rules::check_payments.src/Scheduler.tsx, mounted in the unlocked layout, asks for each due payment once per date and one payment per group at a time.scheduleStarts), and the scheduler waits for that history to load after unlock.Testing
tests/group_schedules.rs: two apps over a real frostd.schedules.test.tsx: making a schedule, the card's details, stopping, and the delay-rule block.scheduler.test.tsx: asked once, then recorded sent.scheduler-retry.test.tsx: a start error is shown and not retried at once.cargo clippy --workspace --all-targets -D warningsandcargo test --workspacepass; vitest passes 60 of 60.🤖 Generated with Claude Code