nikivdev/code · error

Rise daemon returned empty commit message

Error message

Rise daemon returned empty commit message

What it means

Thrown when the Rise daemon (local AI proxy) response was parsed successfully but the extracted commit message is empty after trimming. Indicates the daemon replied but produced no usable message text.

Source

Thrown at src/commit.rs:12821

        ],
        temperature: 0.3,
    };

    info!(model = model, "calling Rise daemon for commit message");
    let start = std::time::Instant::now();

    let rise_url = rise_url();
    let text = send_rise_request_text(&client, &rise_url, &body, model)?;

    info!(
        elapsed_ms = start.elapsed().as_millis() as u64,
        "Rise daemon responded"
    );
    let message = parse_rise_output(&text).context("failed to parse Rise response")?;

    let message = message.trim().to_string();
    if message.is_empty() {
        bail!("Rise daemon returned empty commit message");
    }

    Ok(trim_quotes(&message))
}

/// Generate commit message using OpenRouter API directly.
fn generate_commit_message_openrouter(
    diff: &str,
    status: &str,
    truncated: bool,
    model: &str,
) -> Result<String> {
    let api_key = openrouter_api_key()?;
    let model_id = openrouter_model_id(model);

    let mut user_prompt =
        String::from("Write a git commit message for the staged changes.\n\nGit diff:\n");
    user_prompt.push_str(diff);

View on GitHub (pinned to a747e741ae)

Solutions

  1. Check the Rise daemon is healthy and its upstream model is available (restart it if needed).
  2. Run the request against the daemon directly (curl) to inspect the raw response text.
  3. Verify `parse_rise_output` still matches the daemon's current response format.
  4. Update or reinstall the Rise daemon to a matching version.
Defensive patterns

Strategy: fallback

Validate before calling

// Health-check the Rise daemon before generating
let healthy = reqwest::get("http://127.0.0.1:<port>/health").await
    .map(|r| r.status().is_success()).unwrap_or(false);
if !healthy { return Err(anyhow!("Rise daemon not healthy")); }

Type guard

fn rise_message_valid(parsed: &Option<String>) -> bool {
    parsed.as_deref().map(|m| !m.trim().is_empty()).unwrap_or(false)
}

Try / catch

match result {
    Err(e) if e.to_string().contains("Rise daemon returned empty") => {
        eprintln!("Rise daemon returned nothing; falling back to local generation");
        fallback_to_local_message()
    }
    other => other,
}

Prevention

When it happens

Trigger: Rise daemon is running but returns an empty/blank message body; `parse_rise_output` extracts nothing meaningful from the response text; the daemon's upstream model returns an empty completion.

Common situations: Rise daemon misconfigured or its upstream model unavailable; daemon version change altered output format so `parse_rise_output` no longer extracts text; daemon degraded mode returning empty payloads.

Related errors


AI-assisted analysis of nikivdev/code@a747e741ae (2026-09-01). Data as JSON: /api/errors/1b7427cdec406b49. Report an issue: GitHub.