Skip to main content

validate_input

Function validate_input 

Source
pub fn validate_input(
    args: Value,
    manifest: &Manifest,
    cell_map: &CellMap,
) -> Result<ValidatedInput, WorkbookToolError>
Expand description

Validate + tier-check the raw tool args against the manifest + cell_map, fail-closed.

§Errors

Returns a WorkbookToolError (NOT an Err the handler surfaces as a protocol error — the handler renders it as isError:true) when:

  • arg-parse / deny_unknown_fields fails (invalid_input);
  • an inputs key is not a known cell_map json_key (invalid_input, WR-05);
  • a supplied input’s seed_coord has no manifest role (invalid_input, WR-05);
  • a value fails its declared dtype or closed-enum membership (invalid_input, WR-01/WR-02);
  • an overrides key resolves to a strict constant (strict_constant_override, V4) or to no manifest cell (unsupported_option).