anthropics / anthropics/claude-code

Desktop scheduled tasks: model selection broken end-to-end (spawns ignore user settings; documented picker absent; MCP tool lacks model param)

オープン
#91,884 コメント 5 件 リアクション 0 件 担当者 0 名 GitHub で見る
area:desktop area:routines bug documentation has repro platform:macos
主要言語
Python
スター
145k
フォーク
23.1k
PR マージ指標
PR 指標を取得中

説明

# Bug report: Desktop scheduled tasks — model selection broken end-to-end

**Environment:** Claude Desktop (macOS) 1.24012.9, claude-code CLI 2.1.219+, macOS Darwin 25.5.0.
Two desktop profiles under one account, each with its own scheduled-task registry.

## Summary

There is currently **no working way to control which model a desktop scheduled task runs on**, and scheduled-task spawns only sometimes honor user settings.
Three independent defects compound:

### 1. Scheduled-task spawns ignore user settings on most runs (primary bug)

User settings: `"model": "best"`, `"effortLevel": "xhigh"`, `"fallbackModel": ["claude-opus-5"]`, no env overrides, no managed settings.
Across **148 scheduler-spawned sessions (Jun 3 – Sep 3)** the session records show exactly two spawn profiles:

- **Profile A (116 sessions):** stamps the newest Opus `[1m]` model, no `effort` key, no `sessionSettings`. Ignores user settings entirely. Never once produced Fable 5 (consistent with no `fable[1m]` variant existing).
- **Profile B (32 sessions):** inherits user settings and the app's live ultracode state (`sessionSettings: {"ultracode": true}`, `effort: "xhigh"`, model resolving per the `best` alias → `claude-fable-5`). Every observed Fable run is Profile B.

Which profile a run gets **flips per run, not per task** — e.g. on 2026-09-03 the 07:53 task spawned Profile B (`claude-fable-5`, ultracode) and the 08:24 task spawned Profile A (`claude-opus-5[1m]`), same build, same profile, 31 minutes apart.
Selection is recorded nowhere (task store, session records, settings) and matches no documented behavior.

### 2. The documented Edit-form model picker is absent

`desktop-scheduled-tasks` docs: *"The instructions input includes pickers for the permission mode and model."*
In build 1.24012.9 the Edit form shows **no model picker**. No changelog entry indicates when this feature shipped or its gating.

### 3. The documented "ask Claude" fallback cannot work

Same docs say the task model can be changed "through the Edit form **or ask Claude**."
The `update_scheduled_task` / `create_scheduled_task` MCP tools accept only
`taskId, prompt, description, cronExpression, fireAt, enabled, notifyOnCompletion` — **no model parameter** (schema re-fetched 2026-08-03, 2026-08-21, 2026-09-03; unchanged).
The task store (`claude-code-sessions///scheduled-tasks.json`) carries no model-like key on any of 20 task entries across both profiles.

## Impact

Users who need a specific model on unattended scheduled runs (e.g. Fable 5 with Opus fallback) cannot get it deterministically:
~78% of runs draw Profile A and silently execute on a model the user did not choose, at default effort, with ultracode orchestration silently absent.
Headless runs surface no notice of any of this.

## Requests

1. Make all scheduled-task spawns resolve model/effort from user settings (or document why Profile A exists and how to disable it).
2. Ship the per-task model picker the docs already describe, or correct the docs.
3. Add `model` (and ideally `effort`) parameters to `update_scheduled_task` / `create_scheduled_task` so the documented "ask Claude" path works.

## Evidence available on request

Full session-record analysis (148 spawns with timestamps/models/effort/sessionSettings), task-store dumps from both profiles, settings history with backups.

コントリビューションガイド

このリポジトリのコントリビューションガイドは索引されていません

調査の方向性

Start by reading the desktop-scheduled-tasks documentation and inspecting the scheduled-tasks.json entries under claude-code-sessions//. Re-fetch the create_scheduled_task and update_scheduled_task MCP schemas and compare them with the documented Edit form. Done means the model selection behavior, picker, and MCP parameters are either implemented consistently or the documentation explains their actual limits.

索引モデルが issue の本文から書いたものです。

評価

技術スタック
macos
領域
api, desktop, documentation
issue の種類
バグ
難易度
5/5
見積もり時間
1週間以上
活発さ
活発
明瞭さ
説明が足りない
初心者へのやさしさ
25/100

新しい issue をメールで受け取る

初心者向けの GitHub issue を短くまとめたダイジェスト。