Agent Upstart

Cool things people are building with agents — and practical help getting the most out of them.

Playbooks · Coding tasks

Claude Code 2.1.317: schedule warnings and cost reports

Written November 4, 2026

Scheduled tasks warn about unasked connectors, hooks can block on failure, and gateways get a cost report. The changes that affect daily use.

What changed

Claude Code 2.1.317 adds a warning where a scheduled task could silently gain access it was never given. When a new cloud scheduled task created through /schedule gets connectors the user did not ask for, the changelog says a warning now appears, with instructions for removing them. A scheduled task runs without its creator watching, so a connector added by default is access granted by default — the warning makes that visible at creation time, when it can still be removed.

The release also adds a check on the account email address. Before a web or shell tool call sends the account email address to the network, Claude Code now asks first. The changelog states the check for web and shell tool calls; it states nothing broader, and this page claims nothing broader. An email address leaving the machine through any other route is outside what this entry describes.

For builders using the Agent SDK, hook callbacks gain a failure mode with teeth. A callback can now use onFailure: "block", so a callback that fails blocks the action instead of letting it run. This is an option a callback sets, not a new default for every hook: callbacks without the setting keep their previous behaviour, and the decision to block on failure belongs to each callback's author, weighing a stopped action against an unchecked one.

Gateway administrators get the release's reporting change. The Claude apps gateway admin API gains a cost report at GET /v1/organizations/analytics/cost, reading past spend over a date range in total, per developer, per day, or per IdP group. The report groups by a daily record of each developer's IdP groups, kept on gateways with admin: set for as long as admin.identity_retention_days specifies. It is a report for administrators, not a new dashboard for every subscriber, and it reads past spend rather than forecasting it.

Four smaller changes complete the set of items that affect daily use. Setting CLAUDE_CODE_DISABLE_NESTED_SESSION_ID to 1 on a self-hosted runner makes claude -p run inside a session use that session's ID and transcript, as in earlier versions. Four OpenTelemetry fields — anthropic.plan, anthropic.seat_type, anthropic.provider, and anthropic.custom_base_url — are added to metrics, events, and spans. A fix stops project and local MCP servers disconnecting after the first turn in some Claude Desktop sessions. The Read tool's "file unchanged since your last Read" stub is gone: reading an unchanged file again returns its content. Subagents and teammates running a different model from the main conversation now use that model's saved effort level or its default, instead of the session's effort level. The release carries 62 bug fixes in total; the rest are not listed here.

After upgrading, check

  1. Review your scheduled tasks for connectors you did not ask for. Create one new cloud scheduled task through /schedule and read the result for the warning. Then list the tasks already running and remove any connector you did not ask for: the warning covers new tasks at creation, and existing tasks need a manual look.
  2. Expect a prompt before a web or shell call sends your account email. If a workflow sends the account email through a web or shell tool call, plan for the prompt in unattended runs — an approval that never arrives is a stalled run. Do not assume the same check covers other tool calls; the changelog names web and shell only.
  3. Decide, per hook callback, whether failure should block. For each Agent SDK hook callback, ask what a failure means: if the callback exists to enforce a rule, set onFailure: "block" so a failed check stops the action. If the callback only observes or logs, blocking on its failure trades a missed log line for a stopped task. The setting is per callback, so the decision is too.
  4. Gateway admins: read the cost report and check the retention setting. Call GET /v1/organizations/analytics/cost for a past date range and confirm the per-developer, per-day, and per-IdP-group breakdowns return. Confirm admin.identity_retention_days covers the range you need: IdP-group history older than the retention period is not there to group by.
  5. Self-hosted runners: check nested claude -p behaviour. If a workflow runs claude -p inside a session on a self-hosted runner, confirm whether it now shares the session's ID and transcript, and set CLAUDE_CODE_DISABLE_NESTED_SESSION_ID=1 only if that earlier behaviour is what the workflow needs.
  6. Expect re-reads to return content again. Scripts or habits built around the Read stub — a short "unchanged" reply standing in for the file — will now see the full content on every read. If a workflow parsed the stub's reply, update it before it mistakes file content for an error.

Limits

Related playbooks

Sources

Back to: Coding playbooks hub · Also: Claude Code 2.1.318: sign-in expiry and fork effort