Repository navigation
fix: make automation billing accounts explicit - #201288
roboclaw-bot wants to merge 30 commits into
Conversation
Co-authored-by: vyctorbrzezowski <[email protected]>
Worked on by: - @vyctorbrzezowski Co-authored-by: vyctorbrzezowski <[email protected]> OpenClaw-Publication: e1458b99-060d-858f-a8bd-316c22a9bdd2
|
🦞👀 Pull request received. I will update this pull request when review starts. ClawSweeper review completeClawSweeper finished reviewing this revision. The review result is being finalized. |
|
Codex review: passed. What this changesThis PR replaces hidden automation billing bindings with explicit model-profile pins and migrates existing saved accounts. Example: A weekly report has privately recorded account openai:reports while inheriting openai/gpt-4.1.
Review scores
ProductKind: Preference · Worth it: Yes · Fix scope: Complete Merge readiness✅ Ready for maintainer review Keep open: this maintainer-authored PR provides a coherent account-selection cutover that current main does not implement; no definite introduced code defect was found. Reviewed head: Before mergeNone. FindingsNone. Agent review detailsHow this fits togetherAutomation creation and editing persist scheduled jobs; startup and Doctor migrate old definitions, and scheduled execution resolves their model, runtime, and credentials before contacting a provider. flowchart TD
A[Automation editor or CLI] --> B[Gateway validation]
B --> C[Cron mutation owner]
D[Startup or Doctor migration] --> C
C --> E[Stored cron definitions]
E --> F[Scheduled run admission]
F --> G[Model and credential selection]
G --> H[Provider request]
Technical reviewBest possible solution: Complete the explicit-pin cutover through the existing credential owner and backed-up migration, preserving the documented fallback and ownership-transfer behavior. Do we have a high-confidence way to reproduce the issue? Current-main source establishes private account bindings and unrecorded-account refusals, and the inspected before/after screenshots establish the hidden-choice problem; this review did not run the product. Is this the best way to solve the issue? Reusing model@profile and the shared credential owner removes competing account-selection state while the migration preserves existing billing choices and explains pauses. AGENTS.md: found and applied where relevant. Codex review notes: model internal, reasoning medium; reviewed against c9e795f1bcbd. Provenance checked
TestingProof path: shipped entry point. SecurityNone. EvidenceWhat I checked:
Likely related people:
PR surfacePR surface statistics unavailable: the file list is incomplete. Preflight sourceSource unknown. Source comparison at the observed PR snapshot only. Completion is self-reported; body, policy, tests, execution, and report bytes are not verified. Review metrics
LabelsLabel changes: No label changes. Label justifications:
Rating scale6/6 🦀 challenger crab · 5/6 🦞 diamond lobster · 4/6 🐚 platinum hermit · 3/6 🦐 gold shrimp · 2/6 🦪 silver shellfish · 1/6 🧂 unranked krab. Overall follows the weaker of proof and patch quality; ✨ marks media proof (a screenshot, video, or linked artifact) that directly shows the changed behavior. WorkflowClawSweeper edits this one comment on every review. Comment HistoryReview history (15 earlier review cycles; latest 8 shown)
Reviewed November 28, 2026, 9:11 AM ET / 14:11 UTC (Revision 16). |
Merge main without rewriting the PR history. Keep legacy account rows available for Doctor conversion and preserve explicit model pins across default changes. Co-authored-by: daniel-lxs <[email protected]>
|
@clawsweeper re-review |
|
🦞👀 Re-review progress:
|
143cdde to
251216f
Compare
|
@clawsweeper re-review |
|
🦞👀 Re-review progress:
|
Co-authored-by: vyctorbrzezowski <[email protected]> Co-authored-by: daniel-lxs <[email protected]>
|
@clawsweeper re-review |
|
🦞👀 Re-review progress:
|
Co-authored-by: vyctorbrzezowski <[email protected]> Co-authored-by: daniel-lxs <[email protected]>
|
@clawsweeper re-review |
|
🦞👀 Re-review progress:
|
Co-authored-by: vyctorbrzezowski <[email protected]> Co-authored-by: daniel-lxs <[email protected]>
|
@clawsweeper re-review |
|
🦞👀 Re-review progress:
|
Use the account selection from #202833, including explicit session accounts. Keep existing account captures, model aliases and upgrade-receipt recovery. Remove the obsolete boot adoption of jobs without a saved account.
Expose the account selection alongside the saved model without publishing the authorization record or changing how edits and model aliases work.
What problem this solves
A scheduled prompt can keep using a billing account that its owner cannot see in Automations. Another job, created without a saved account, can stop when its conversation switches to a stored account that works in chat.
User impact
Open the automation or run
openclaw automations show <jobId>to see the saved billing account. A job that selects its account at run time says so. An automation can follow a model alias and keep its chosen account when the alias moves.A prompt with no saved account uses the account selected by its agent or conversation. A recorded account still governs its own provider, including refusal if the credential is removed or replaced. New main-session reminders follow their chat. Older reminders can still adopt an account through Doctor or an explicit account edit. Account selection · Main-session reminder recovery · Operator reports
Evidence
Compared main
b9ddb611c5with the PR runtime82b133b053.Both private Gateways opened copies of the same SQLite state. A local model served requests through three synthetic accounts. The provider default was
openai:studio.openai:dailyopenai:dailyGardenalias moved fromgpt-4.1togpt-4ogpt-4oonopenai:reports. The account was hidden.gpt-4oonopenai:reports. The UI and CLI showed the saved account.openai:reportsafter the edit.Both builds retained the original successful alias run and the recorded account authorization. A separate 2026.11.11 Gateway reproduced the unbound-job refusal. The source package identifies itself as 2026.11.10 and refused the 2026.11.11 configuration, so the paired comparison used state created on main.
Core and Control UI typechecks, touched-file lint, formatting, and both runtime builds passed. Across the local runs, 31 distinct focused cases passed. The migration test that timed out during unrelated Doctor setup exercises the account repair directly under offline maintenance and passed in 47 seconds. The adjacent personal-account case and the Gateway alias regression also passed.
Automation details
Chromium shows the saved account and the run-time selection on the same two automations. Each image stacks matching crops from the real Control UI.
Main
PR
Annotated comparison
Main
PR
Co-authored by Vyctor Brzezowski.
Work sessions
Linked for team reference; these sessions aren’t public.
Worked on by