zeroclaw-labs/zeroclaw · error · anyhow::Error

Unsupported find_action '{action}'. Use click/fill/text/hove

Error message

Unsupported find_action '{action}'. Use click/fill/text/hover/check

What it means

The find action locates an element by `by`/`value`, then dispatches on find_action: click, fill (which additionally requires fill_value), text, hover, and check. The final match arm rejects every other string, so a mistyped or unsupported find_action fails before any element interaction.

Source

Thrown at crates/zeroclaw-tools/src/browser.rs:1850

                            json!({"result": "text", "text": text})
                        }
                        "hover" => {
                            hover_element(client, &element).await?;
                            json!({"result": "hovered"})
                        }
                        "check" => {
                            let checked_before = element_checked(&element).await?;
                            if !checked_before {
                                element.click().await?;
                            }
                            let checked_after = element_checked(&element).await?;
                            json!({
                                "result": "checked",
                                "checked_before": checked_before,
                                "checked_after": checked_after,
                            })
                        }
                        _ => anyhow::bail!(
                            "Unsupported find_action '{action}'. Use click/fill/text/hover/check"
                        ),
                    };

                    Ok(json!({
                        "backend": "rust_native",
                        "action": "find",
                        "by": by,
                        "value": value,
                        "selector": selector,
                        "data": payload,
                    }))
                }
            }
        }

        pub async fn reset_session(&mut self) {
            if let Some(client) = self.client.take() {

View on GitHub (pinned to 88bb9c8533)

Solutions

  1. Use one of click/fill/text/hover/check exactly, lowercase
  2. For fill, also include fill_value — a separate error fires when it is missing
  3. Constrain find_action in the tool schema or prompt examples to the five legal values

Example fix

// before
{"action": "find", "by": "id", "value": "out", "find_action": "read"}
// after
{"action": "find", "by": "id", "value": "out", "find_action": "text"}
Defensive patterns

Strategy: validation

Validate before calling

const FIND_ACTIONS: &[&str] = &["click", "fill", "text", "hover", "check"];
if !FIND_ACTIONS.contains(&find_action) {
    return Err(format!("unsupported find_action: {find_action}"));
}
if find_action == "fill" && fill_value.is_none() {
    return Err("find_action='fill' requires fill_value".into());
}

Try / catch

match tool.execute(args).await {
    Ok(res) => { /* ... */ }
    Err(e) if e.to_string().contains("Unsupported find_action") => {
        // replace with one of click/fill/text/hover/check
    }
    Err(e) => return Err(e),
}

Prevention

When it happens

Trigger: Sending {"action": "find", "by": "id", "value": "submit", "find_action": "submit"} — also 'select', 'clear', 'read', or capitalized variants like 'Click' (case-sensitive).

Common situations: Models proposing form verbs the tool does not implement (select, upload, focus); case drift from examples; forgetting that reading text is "text", not "read".

Related errors


AI-assisted analysis of zeroclaw-labs/zeroclaw@88bb9c8533 (2026-08-23). Data as JSON: /api/errors/e26a091f4e43f3f9. Report an issue: GitHub.