{"record":{"id":"7eb9675c7ea756de","repo":"googleapis/mcp-toolbox","slug":"failed-to-list-labels-w","errorCode":null,"errorMessage":"failed to list labels: %w","messagePattern":"failed to list labels: %w","errorType":"exception","errorClass":null,"httpStatus":null,"severity":"error","filePath":"internal/tools/falkordb/falkordbschema/falkordbschema.go","lineNumber":286,"sourceCode":"\t\t\t\terrs <- err\n\t\t\t}\n\t\t}(task.fn)\n\t}\n\twg.Wait()\n\tclose(errs)\n\tfor err := range errs {\n\t\treturn nil, err\n\t}\n\n\treturn schema, nil\n}\n\n// extractNodeLabels lists the node labels and derives each label's count and\n// property shapes from a sample of nodes.\nfunc (t Tool) extractNodeLabels(ctx context.Context, source compatibleSource) ([]types.NodeLabel, error) {\n\tlabelsResult, err := runReadQuery(ctx, source, \"CALL db.labels()\")\n\tif err != nil {\n\t\treturn nil, fmt.Errorf(\"failed to list labels: %w\", err)\n\t}\n\n\tvar nodeLabels []types.NodeLabel\n\tfor _, label := range helpers.FirstColumnStrings(labelsResult) {\n\t\tescaped := escapeIdentifier(label)\n\n\t\tcountResult, err := runReadQuery(ctx, source, fmt.Sprintf(\"MATCH (n:`%s`) RETURN count(n) AS count\", escaped))\n\t\tif err != nil {\n\t\t\treturn nil, fmt.Errorf(\"failed to count label %q: %w\", label, err)\n\t\t}\n\n\t\tsampleResult, err := runReadQuery(ctx, source, fmt.Sprintf(\"MATCH (n:`%s`) RETURN n LIMIT %d\", escaped, t.Cfg.SampleSize))\n\t\tif err != nil {\n\t\t\treturn nil, fmt.Errorf(\"failed to sample label %q: %w\", label, err)\n\t\t}\n\t\taccumulator := make(map[string]map[string]bool)\n\t\tfor _, row := range helpers.Rows(sampleResult) {\n\t\t\tnode, ok := row[\"n\"].(map[string]any)","sourceCodeStart":268,"sourceCodeEnd":304,"githubUrl":"https://github.com/googleapis/mcp-toolbox/blob/8cc6e09de2ad7b8bffc77751799585a1401a48eb/internal/tools/falkordb/falkordbschema/falkordbschema.go#L268-L304","documentation":"Wrap inside extractNodeLabels: the 'CALL db.labels()' procedure failed, so the node-label inventory that drives per-label counts and sampling could not even be listed.","triggerScenarios":"Thrown at internal/tools/falkordb/falkordbschema/falkordbschema.go:286 when the library encounters an invalid state.","commonSituations":"See trigger scenarios.","solutions":["Inspect the wrapped error for the underlying FalkorDB failure","Verify the connection and database 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"}