{"record":{"id":"a4e1daacfb3395ec","repo":"hasura/graphql-engine","slug":"expected-to-find-a-predicate-type-for-argument-ar","errorCode":null,"errorMessage":"expected to find a predicate type for argument {argument_name:} but did not","messagePattern":"expected to find a predicate type for argument (.+?) but did not","errorType":"validation","errorClass":"TypeMappingValidationError","httpStatus":null,"severity":"error","filePath":"v3/crates/metadata-resolve/src/stages/object_types/error.rs","lineNumber":127,"sourceCode":"        field_name: FieldName,\n        unknown_field_type_name: Qualified<CustomTypeName>,\n    },\n    #[error(\n        \"could not find mappings for {object_type_name:} to the {data_connector_object_type:} on data connector {data_connector_name:}\"\n    )]\n    DataConnectorTypeMappingNotFound {\n        object_type_name: Qualified<CustomTypeName>,\n        data_connector_name: Qualified<DataConnectorName>,\n        data_connector_object_type: DataConnectorObjectType,\n    },\n    #[error(\n        \"the type {unknown_ndc_type:} is not defined as an object type in the connector's schema. This type is being mapped to by the type {type_name:}\"\n    )]\n    UnknownNdcType {\n        type_name: Qualified<CustomTypeName>,\n        unknown_ndc_type: DataConnectorObjectType,\n    },\n    #[error(\"expected to find a predicate type for argument {argument_name:} but did not\")]\n    PredicateTypeNotFound { argument_name: ArgumentName },\n    #[error(\n        \"the type {unknown_ndc_field_type_name:} is not defined as an object type in the connector's schema. This type is referenced by the field {ndc_field_name:} in the connector's schema type {ndc_type_name:}, which is mapped to the field {field_name:} in the type {type_name:}\"\n    )]\n    UnknownNdcFieldObjectType {\n        type_name: Qualified<CustomTypeName>,\n        field_name: FieldName,\n        ndc_type_name: String,\n        ndc_field_name: String,\n        unknown_ndc_field_type_name: String,\n    },\n    #[error(\"ndc validation error: {0}\")]\n    NDCValidationError(#[from] NDCValidationError),\n}\n","sourceCodeStart":109,"sourceCodeEnd":142,"githubUrl":"https://github.com/hasura/graphql-engine/blob/724551b9ae87845594ef0408cff0e50eb6c90dc5/v3/crates/metadata-resolve/src/stages/object_types/error.rs#L109-L142","documentation":"During object type resolution the resolver looked up the predicate (filter) type corresponding to an argument name of a comparison operator and did not find it. Comparison operators declared by the connector must have a predicate type entry; if the argument name has no matching predicate type, resolution fails.","triggerScenarios":"A data connector declares comparison operator functions whose argument names do not match any predicate type name, or the generated filter object types for the mapped type are missing/renamed in the metadata while enable_ordering/filtering is on.","commonSituations":"Custom comparison operators added in metadata with a wrong argument name; connector versions that change operator argument conventions; hand-written predicate types that omit an entry for a new argument.","solutions":["Check the comparison operator definitions in metadata and make sure each argument_name has a corresponding predicate type","Ensure the filter/predicate object types generated for the type are present and named consistently with operator arguments","Update the connector to a version whose operator signatures match the metadata"],"exampleFix":null,"handlingStrategy":"validation","validationCode":"// Verify each comparison operator argument has a matching predicate type before apply\nfor (const op of comparisonOperators) {\n  if (!predicateTypeNames.has(op.argument_name)) throw new Error(`Missing predicate type for argument ${op.argument_name}`);\n}","typeGuard":null,"tryCatchPattern":null,"preventionTips":["Generate predicate object types together with operator definitions","Keep operator argument names in sync with predicate type names when upgrading connectors"],"tags":["hasura","metadata","data-connectors","predicates","operators"],"backgroundTag":"predicate-type-not-found","analyzedSha":"724551b9ae87845594ef0408cff0e50eb6c90dc5","analyzedAt":"2026-08-28T07:32:55.105Z","schemaVersion":2},"datasetVersion":"2026-08-28T11:17:15.048Z"}