Skip to content

feat(schedule): executors build a job per fire; supervisor takes argv payloads - #216

Merged
drknowhow merged 1 commit into
mainfrom
feat/scheduled-tasks-runner
Oct 13, 2026
Merged

drknowhow merged 1 commit into
mainfrom
feat/scheduled-tasks-runner

Conversation

@drknowhow

Copy link
Copy Markdown
Owner

Stacked on #215. Second of the Scheduled Tasks series.

  • services/schedule_runner.py: plan() builds the command for one fire per provider (claude -p --output-format json --permission-mode … --permission-prompts none [--model] [--effort] [--max-budget-usd] [--allowedTools] with the prompt on stdin; codex exec -; gemini; grok --prompt-file; or the schedule's plain command). dispatch() starts it as a detached JobStore job; finalize() maps the job's terminal state onto the run and reads cost, tokens, turns and model from the provider's JSON stdout.
  • services/shell_jobs.py supervisor: payload keys argv (launched with no shell through harden_win_argv), stdin_text and env_drop. The cmd path is untouched.
  • docs/shell-jobs.md: the three keys.

No loop reads the store yet; that is the next PR. 39 tests, including a real supervisor run that reads stdin and drops an env var.

https://claude.ai/code/session_01JUcvmQq81aLo9ewD9Xc4qY

@groyep

groyep Bot commented Oct 13, 2026

Copy link
Copy Markdown

Gro could not finish this review.

… payloads

services/schedule_runner.py turns a schedule row into a FirePlan (claude -p
with the prompt on stdin, codex exec -, gemini, grok --prompt-file, or a plain
command), starts it as a detached shell job, and folds the job's exit, cost and
tokens back into the run. The supervisor gains three payload keys: argv (no
shell, harden_win_argv), stdin_text and env_drop, so a headless claude run is
not seen as a nested session. The existing cmd path is unchanged. Not wired to
any loop yet. Verified: 39 tests incl. a real supervisor run with stdin.

Claude-Session: https://claude.ai/code/session_01JUcvmQq81aLo9ewD9Xc4qY
@drknowhow
drknowhow force-pushed the feat/scheduled-tasks-runner branch from bae6372 to 60bc78c Compare October 13, 2026 14:02
@drknowhow
drknowhow changed the base branch from feat/scheduled-tasks-store to main October 13, 2026 14:10
@drknowhow drknowhow closed this Oct 13, 2026
@drknowhow drknowhow reopened this Oct 13, 2026
@groyep

groyep Bot commented Oct 13, 2026

Copy link
Copy Markdown

Gro could not finish this review.

@drknowhow
drknowhow merged commit 1cb4e69 into main Oct 13, 2026
12 checks passed
@drknowhow
drknowhow deleted the feat/scheduled-tasks-runner branch October 13, 2026 14:21
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant