{"record":{"id":"12581fdaf8763a8e","repo":"googleapis/mcp-toolbox","slug":"failed-to-count-nodes-w","errorCode":null,"errorMessage":"failed to count nodes: %w","messagePattern":"failed to count nodes: %w","errorType":"exception","errorClass":null,"httpStatus":null,"severity":"error","filePath":"internal/tools/falkordb/falkordbschema/falkordbschema.go","lineNumber":212,"sourceCode":"\t\t\t\trelationships, err := t.extractRelationships(ctx, source)\n\t\t\t\tif err != nil {\n\t\t\t\t\treturn fmt.Errorf(\"failed to extract relationship schema: %w\", err)\n\t\t\t\t}\n\t\t\t\tmu.Lock()\n\t\t\t\tdefer mu.Unlock()\n\t\t\t\tschema.Relationships = relationships\n\t\t\t\tfor _, relationship := range relationships {\n\t\t\t\t\tschema.Statistics.RelationshipsByType[relationship.Type] = relationship.Count\n\t\t\t\t}\n\t\t\t\treturn nil\n\t\t\t},\n\t\t},\n\t\t{\n\t\t\tname: \"counts\",\n\t\t\tfn: func() error {\n\t\t\t\tnodeResult, err := runReadQuery(ctx, source, \"MATCH (n) RETURN count(n) AS count\")\n\t\t\t\tif err != nil {\n\t\t\t\t\treturn fmt.Errorf(\"failed to count nodes: %w\", err)\n\t\t\t\t}\n\t\t\t\tedgeResult, err := runReadQuery(ctx, source, \"MATCH ()-[r]->() RETURN count(r) AS count\")\n\t\t\t\tif err != nil {\n\t\t\t\t\treturn fmt.Errorf(\"failed to count relationships: %w\", err)\n\t\t\t\t}\n\t\t\t\tmu.Lock()\n\t\t\t\tdefer mu.Unlock()\n\t\t\t\tschema.GraphInfo.NodeCount = helpers.FirstRowInt64(nodeResult)\n\t\t\t\tschema.GraphInfo.EdgeCount = helpers.FirstRowInt64(edgeResult)\n\t\t\t\tschema.Statistics.TotalNodes = schema.GraphInfo.NodeCount\n\t\t\t\tschema.Statistics.TotalRelationships = schema.GraphInfo.EdgeCount\n\t\t\t\treturn nil\n\t\t\t},\n\t\t},\n\t\t{\n\t\t\tname: \"indexes\",\n\t\t\tfn: func() error {\n\t\t\t\tresult, err := runReadQuery(ctx, source, \"CALL db.indexes()\")","sourceCodeStart":194,"sourceCodeEnd":230,"githubUrl":"https://github.com/googleapis/mcp-toolbox/blob/8cc6e09de2ad7b8bffc77751799585a1401a48eb/internal/tools/falkordb/falkordbschema/falkordbschema.go#L194-L230","documentation":"Task-failure wrap inside the concurrent schema extraction: the 'counts' task's node count query ('MATCH (n) RETURN count(n)') failed, aborting the whole schema extraction.","triggerScenarios":"Thrown at internal/tools/falkordb/falkordbschema/falkordbschema.go:212 when the library encounters an invalid state.","commonSituations":"See trigger scenarios.","solutions":["Inspect the wrapped error for the underlying FalkorDB failure","Check graph reachability and server health","Retry the schema extraction once the server is healthy"],"exampleFix":null,"handlingStrategy":"try-catch","validationCode":null,"typeGuard":null,"tryCatchPattern":null,"preventionTips":[],"tags":[],"backgroundTag":null,"analyzedSha":"8cc6e09de2ad7b8bffc77751799585a1401a48eb","analyzedAt":"2026-09-05T01:10:36.887Z","contentChangedAt":"2026-09-05T01:10:36.887Z","schemaVersion":2},"datasetVersion":"2026-09-08T10:18:20.063Z"}