Hmbown/CodeWhale · error

prompt is required

Error message

prompt is required

What it means

Admission guard inside the boxed start-turn future: the StartTurnRequest's prompt field is required and empty at this point, so the turn is rejected before route/classifier resolution and before any durable engine handoff.

Solutions

  1. Supply a non-empty prompt string on the turn request.
  2. For continuations, use the rendered continuation prompt rather than an empty string.
Defensive patterns

Strategy: validation

When it happens

Trigger: Thrown at crates/tui/src/runtime_threads.rs:9823 when the library encounters an invalid state.

Common situations: See trigger scenarios.


AI-assisted analysis of Hmbown/CodeWhale@73e0f67d83 (2026-09-22). Data as JSON: /api/errors/c1aa343b50b26700. Report an issue: GitHub.

Appendix: source

Thrown at crates/tui/src/runtime_threads.rs:9823

        // monolithic frame overflowed it (test
        // start_turn_accepts_dynamic_tools_and_environment_id on windows-latest,
        // STATUS_STACK_OVERFLOW). Box::pin moves the whole frame to the heap so
        // no caller's stack carries it; behavior is unchanged.
        Box::pin(async move {
        // Keep config publication and turn admission in one ordering domain.
        // This read lease spans route/classifier resolution and the durable
        // engine handoff, so a completed reload is a hard boundary: no later
        // dispatch can carry its predecessor's URL, key, model, or policy.
        let _config_admission = self.config_admission.read().await;
        self.ensure_accepting_execution()?;
        let image_blocks = if stored_image_bytes {
            crate::image_attach::prepare_stored_images(&req.images)?
        } else {
            crate::image_attach::prepare_runtime_images(&req.images)?
        };
        let prompt = req.prompt.trim().to_string();
        if prompt.is_empty() {
            bail!("prompt is required");
        }

        let thread = self.get_thread(thread_id).await?;
        let turn_reasoning_preference = req
            .reasoning_effort
            .as_deref()
            .map(parse_runtime_reasoning_effort)
            .transpose()?;
        let thread_reasoning_preference = thread
            .reasoning_effort
            .as_deref()
            .map(parse_runtime_reasoning_effort)
            .transpose()
            .with_context(|| format!("Thread {thread_id} has invalid reasoning_effort"))?;
        let policy =
            if req.mode.is_some() || req.permission_posture.is_some() || req.auto_approve.is_some()
            {
                runtime_policy_with_overrides(

View on GitHub (pinned to 73e0f67d83)