{"record":{"id":"ba80ed51b9022b4f","repo":"hasura/graphql-engine","slug":"error-fetching-server-config-v","errorCode":null,"errorMessage":"error fetching server config: %v","messagePattern":"error fetching server config: (.+?)","errorType":"console","errorClass":null,"httpStatus":null,"severity":"error","filePath":"cli/cli.go","lineNumber":259,"sourceCode":"\t}\n\tdefer r.Body.Close()\n\n\tif r.StatusCode != http.StatusOK {\n\t\tvar horror hasuradb.HasuraError\n\n\t\terr := json.NewDecoder(r.Body).Decode(&horror)\n\t\tif err != nil {\n\t\t\treturn errors.E(\n\t\t\t\top,\n\t\t\t\terrors.KindHasuraAPI,\n\t\t\t\tstderrors.New(\"error unmarshalling fetching server config\"),\n\t\t\t)\n\t\t}\n\n\t\treturn errors.E(\n\t\t\top,\n\t\t\terrors.KindHasuraAPI,\n\t\t\tfmt.Errorf(\"error fetching server config: %v\", horror.Error()),\n\t\t)\n\t}\n\n\treturn nil\n}\n\n// HasuraServerConfig is the type returned by the v1alpha1/config API\n// TODO: Move this type to a client implementation for hasura.\ntype HasuraServerInternalConfig struct {\n\tConsoleAssetsDir string `json:\"console_assets_dir\"`\n}\n\n// GetVersionEndpoint provides the url to contact the version API.\nfunc (c *ServerConfig) GetVersionEndpoint() string {\n\tnurl := *c.ParsedEndpoint\n\tnurl.Path = path.Join(nurl.Path, c.APIPaths.Version)\n\n\treturn nurl.String()","sourceCodeStart":241,"sourceCodeEnd":277,"githubUrl":"https://github.com/hasura/graphql-engine/blob/724551b9ae87845594ef0408cff0e50eb6c90dc5/cli/cli.go#L241-L277","documentation":"Thrown when resolving a type predicate (boolean expression) that must recurse into an object type, but the named custom object type cannot be found in the resolved metadata. This usually means the type was never tracked, was renamed, or resolution ordering dropped it.","triggerScenarios":"A filter predicate or boolean expression type references a CustomTypeName that is absent from the metadata's type map, e.g. a relationship target type that isn't tracked, or a command output type that was removed while predicates on it still exist.","commonSituations":"Renaming or untracking a type without updating relationships/commands that reference it; copy-paste typos in type names in metadata YAML/JSON; partial applies of metadata leaving dangling type references.","solutions":["Check the type name in the error exists and is tracked in metadata","Fix typos or stale references in relationships/commands pointing to the missing type","Re-apply complete metadata rather than partial updates","Look for a prior ObjectTypeNotFound or tracking error that caused this type to be skipped"],"exampleFix":"// before\nkind: relationship\nname: articles\ntargetType: Artical # typo\n// after\nkind: relationship\nname: articles\ntargetType: Article","handlingStrategy":"validation","validationCode":"// Ensure every type referenced by relationships/commands exists in metadata\nconst missing = refs.filter(r => !metadata.types[r.targetType]);\nif (missing.length) throw new Error(`Untracked types: ${missing.map(m => m.targetType)}`);","typeGuard":"const typeExists = (meta, name) => Object.prototype.hasOwnProperty.call(meta.types, name);","tryCatchPattern":"try { resolve(); } catch (e) { if (e?.code === 'ObjectTypeNotFound') suggestTracking(e.type_name); else throw e; }","preventionTips":["Run metadata validation/consistency checks before apply","Automate renames end-to-end so references stay in sync"],"tags":["metadata","type-not-found","boolean-expression","hasura"],"backgroundTag":"unresolved-type-reference","analyzedSha":"724551b9ae87845594ef0408cff0e50eb6c90dc5","analyzedAt":"2026-08-28T07:32:55.105Z","schemaVersion":2},"datasetVersion":"2026-08-28T11:17:15.048Z"}