hasura/graphql-engine · error
expected arguments '{}' on field {field_name} of type {type_
Error message
expected arguments '{}' on field {field_name} of type {type_name} are not found What it means
Thrown by the lang-graphql validator during argument normalization (normalize_arguments in selection_set.rs) when a field's selection references a set of arguments that the server's validation pass expects to find but cannot resolve for that field/type pair. It lists all the missing argument names for the field on the given type. This is a GraphQL document validation error raised before execution.
Source
Thrown at v3/crates/graphql/lang-graphql/src/validation/error.rs:158
variable_type: ast::Type,
},
#[error("the following fragment is defined more than once: {fragment_name}")]
DuplicateFragmentDefinitions { fragment_name: ast::Name },
#[error("the following operation is defined more than once: {operation_name}")]
DuplicateOperationDefinitions { operation_name: ast::Name },
#[error("there should only be one anonymous operation in the document")]
AnonymousOperationMustBeUnique,
#[error("no mutations are defined in the schema")]
NoMutationsAreDefined,
#[error("no subscriptions are defined in the schema")]
NoSubscriptionsAreDefined,
#[error("internal error: selection root is not of object type")]
InternalSelectionRootIsNotObject,
#[error("operation not found: {operation_name}")]
OperationNotFound { operation_name: ast::Name },
#[error("no anonymous operation found in the document")]
AnonymousOperationNotFound,
#[error("expected arguments '{}' on field {field_name} of type {type_name} are not found", argument_names.iter().map(ToString::to_string).collect::<Vec<_>>().join(", "))]
ArgumentsNotFound {
type_name: ast::TypeName,
field_name: ast::Name,
argument_names: Vec<ast::Name>,
},
#[error("argument {argument_name} on field {field_name} of type {type_name} not found")]
ArgumentNotFound {
type_name: ast::TypeName,
field_name: ast::Name,
argument_name: ast::Name,
},
#[error(
"argument {argument_name} on field {field_name} of type {type_name} is defined more than once"
)]
DuplicateArguments {
type_name: ast::TypeName,
field_name: ast::Name,
argument_name: ast::Name,View on GitHub (pinned to 724551b9ae)
Solutions
- Check the query's field arguments against the schema for the reported field_name and type_name
- Ensure argument names match exactly (case-sensitive) the schema definition
- Regenerate client queries if the schema changed
- Add the missing arguments listed in the error message to the field selection
Example fix
# before
query { user { posts(title: "x") { id } } }
# after (argument name fixed to match schema)
query { user { posts(filterTitle: "x") { id } } } Defensive patterns
Strategy: validation
Validate before calling
// Before executing, validate the document against the schema
let errs = lang_graphql::validation::validate(&schema, &mut executable_document)?;
if !errs.is_empty() { /* report errs to caller, don't execute */ } Try / catch
// Match on Error::ArgumentsNotFound { field_name, argument_names, .. } and surface the missing names to the client Prevention
- Validate documents against the schema before execution
- Use codegen clients (graphql-codegen, etc.) so argument names are type-checked
When it happens
Trigger: Executing a GraphQL query/mutation via validate() where a field like `field(arg1: 1, arg2: 2)` is processed and the validator fails to find the expected argument bindings `{arg1, arg2}` on that field of the parent type during normalize_arguments.
Common situations: Hand-written queries with typos in argument names, generated queries out of sync with the schema version, directives (@include/@skip) that strip arguments during normalization, or partially-built schemas in tests.
Related errors
- the fieldName for argumentsInput needs to be defined in Grap
- validation failed: {0}
- Unexpected value: expecting {expected_kind:}, but found: {fo
- '{name:}' is not a valid GraphQL name.
- '{alias:} is not a valid alias
AI-assisted analysis of hasura/graphql-engine@724551b9ae (2026-08-28).
Data as JSON: /api/errors/5f1cc20b62d8d401.
Report an issue: GitHub.