hasura/graphql-engine · error · AggregateBooleanExpressionError
{0}
Error message
{0} What it means
AggregateBooleanExpressionError::GraphqlConfigError is a #[from] conversion that transparently forwards ({0}) any GraphqlConfigError raised while reading the GraphQL configuration block of an aggregate boolean expression type (e.g. its GraphQL type name).
Source
Thrown at v3/crates/metadata-resolve/src/stages/aggregate_boolean_expressions/types.rs:134
pub type_name: Qualified<CustomTypeName>,
pub error: AggregateBooleanExpressionError,
}
impl ContextualError for NamedAggregateBooleanExpressionError {
fn create_error_context(&self) -> Option<error_context::Context> {
None
}
}
#[derive(Debug, thiserror::Error)]
pub enum AggregateBooleanExpressionError {
#[error("boolean expressions with aggregate operands are not supported")]
AggregateBooleanExpressionsNotSupported,
#[error("boolean expressions with aggregate operands do not support isNull comparisons")]
IsNullComparisonsNotSupported,
#[error("{0}")]
GraphqlConfigError(#[from] GraphqlConfigError),
#[error("the operand type '{operand_type}' must be a scalar type")]
OperandTypeIsNotAScalarType {
operand_type: Qualified<CustomTypeName>,
},
#[error("the operand type '{operand_type}' must be an object type")]
OperandTypeIsNotAnObjectType {
operand_type: Qualified<CustomTypeName>,
},
#[error("the aggregate expression '{aggregate_expression}' could not be found")]
AggregateExpressionNotFound {
aggregate_expression: Qualified<AggregateExpressionName>,
},
#[error(View on GitHub (pinned to 724551b9ae)
Solutions
- Inspect the underlying GraphqlConfigError message for the exact config problem
- Fix or add the graphql type_name for the aggregate boolean expression type
- Validate GraphQL naming rules (letters, digits, underscores, not starting with a digit)
Example fix
# before graphql_config: type_name: "invalid name!" # after graphql_config: type_name: UserAggregateExpression
Defensive patterns
Strategy: validation
Validate before calling
fn valid_graphql_name(name: &str) -> bool {
let mut chars = name.chars();
matches!(chars.next(), Some(c) if c.is_alphabetic() || c == '_')
&& chars.all(|c| c.is_alphanumeric() || c == '_')
} Try / catch
if let AggregateBooleanExpressionError::GraphqlConfigError(inner) = err {
eprintln!("fix graphql_config: {inner}");
} Prevention
- Always provide a valid graphql type_name in graphql_config
- Use GraphQL-name linters on metadata
- Reuse a consistent naming convention (PascalCase type names)
When it happens
Trigger: Providing a graphql_config for an aggregate boolean expression whose type_name is missing, malformed, or conflicts with existing GraphQL type naming rules.
Common situations: Typos in the graphql config section, missing type_name field, invalid GraphQL type names (spaces, leading digits) in the boolean expression's GraphQL configuration.
Related errors
- error in boolean expression type '{type_name}': {error}
- boolean expressions with aggregate operands are not supporte
- boolean expressions with aggregate operands do not support i
- the operand type '{operand_type}' must be a scalar type
- the operand type '{operand_type}' must be an object type
AI-assisted analysis of hasura/graphql-engine@724551b9ae (2026-08-28).
Data as JSON: /api/errors/e5c503a0296d67d3.
Report an issue: GitHub.