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
{{ message }}
Repository navigation
fix(purchase): the fire sweep overwrites approved_by with "scheduler" #1589
FireScheduledDelayedPurchases (internal/purchase/scheduled_fire.go) stamps ApprovedBy = "scheduler" when it fires a delayed purchase, replacing the email of the person who approved it. Every delayed approval (purchase_delay_hours > 0) loses its approver in purchase_executions and in what History shows. #1580 turned the sweep on by default, so this now happens on every install that sets a delay. The migrated default is 0, which executes approvals immediately and isn't affected.
Fix: keep the approver's identity in approved_by and record that the scheduler fired it in a separate field or audit event. Add a test that fires a delayed approval and checks the approver is kept.
Found in review of #1580. The behavior predates #1580.
Claimed by orchestrator run 2026-11-04 (platform-burndown). The plan has passed two adversarial review passes; implementation follows in a PR that closes this issue.
Fixed by #1669, merged as 76ca37e. Verified locally on real Postgres with the real fire sweep and a fake provider: a scheduled purchase approved by a user keeps that approver in approved_by after it fires, and a row with no approver stays NULL (main wrote "scheduler" in both cases). Independent Opus review and the gate record are on the PR. Known gap, by design: rows already stored as "scheduler" before this fix keep that value (no backfill).
Activity
cristim commentedon Nov 4, 2026
Claimed by orchestrator run 2026-11-04 (platform-burndown). The plan has passed two adversarial review passes; implementation follows in a PR that closes this issue.
cristim commentedon Nov 4, 2026
Fixed by #1669, merged as 76ca37e. Verified locally on real Postgres with the real fire sweep and a fake provider: a scheduled purchase approved by a user keeps that approver in approved_by after it fires, and a row with no approver stays NULL (main wrote "scheduler" in both cases). Independent Opus review and the gate record are on the PR. Known gap, by design: rows already stored as "scheduler" before this fix keep that value (no backfill).
fix(purchase): keep stored approver when the fire sweep claims a dela…