Skip to content

Let manual schedule fire honor runner wake budgets #348

Description

@mostlydev

Problem

claw api schedule fire is a synchronous, final-result-bearing operator command, but both client transport layers time out well before runner-specific wake budgets:

  • cmd/claw-api/main.go local client mode defaults -request-timeout to 10 seconds.
  • cmd/claw/api.go bounds the outer docker compose exec transport at 15 seconds.
  • claw-api's wake adapter currently allows OpenClaw up to two minutes, and hermes: extend scheduled wake timeout #346 proposes the same evidence-based budget for Hermes.

A healthy manual wake can therefore be canceled by the client around 10 seconds even though the server-side adapter is allowed to keep waiting. The operator sees a timeout, the request context cancels the in-container exec, and schedule state can contradict the runner outcome.

Required behavior

  1. Manual fire remains synchronous and returns the final scheduler outcome.
  2. The local claw-api request timeout and outer compose-exec timeout cover the selected scheduler wake budget plus a small transport margin.
  3. Read-only and fast schedule control commands keep short defaults; do not make every claw-api request wait minutes.
  4. Timeout ownership stays in the operator/client and claw-api transport surfaces. Do not add runner prompt behavior, downstream wrappers, or cllama logic.
  5. Cancellation before a wake attempt must remain neutral in schedule failure/degraded accounting (see Prevent slow scheduled wakes from blocking unrelated invocations #347).

Suggested shape

Give the fire subcommand an explicit longer transport budget and pass a matching -request-timeout to claw-api local client mode. Keep the generic --exec-timeout override available and document its precedence. If adapter-specific discovery is not available at the CLI layer, use a schedule-fire budget that safely covers the longest server-supported wake timeout.

Verification

  • focused CLI argument/timeout tests for schedule fire
  • other schedule operations retain their current short timeout
  • an in-process delayed fire response beyond 15 seconds succeeds under the fire-specific budget
  • go test ./cmd/claw-api ./cmd/claw
  • go test ./...
  • go vet ./...
  • git diff --check

Relationship

PR #346 fixes Hermes server-side timeout selection but cannot fully resolve its manual-fire scenario until this client deadline is aligned. #347 separately handles scheduler concurrency and neutral cancellation.

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions