{"record":{"id":"48d5a1f68eb727f7","repo":"googleapis/mcp-toolbox","slug":"description-is-required-for-tool-q-48d5a1","errorCode":null,"errorMessage":"description is required for tool %q","messagePattern":"description is required for tool %q","errorType":"validation","errorClass":null,"httpStatus":null,"severity":"error","filePath":"internal/tools/falkordb/falkordbexecutecypher/falkordbexecutecypher.go","lineNumber":69,"sourceCode":"type Config struct {\n\ttools.ConfigBase   `yaml:\",inline\"`\n\tType               string                 `yaml:\"type\" validate:\"required\"`\n\tSource             string                 `yaml:\"source\" validate:\"required\"`\n\tReadOnly           bool                   `yaml:\"readOnly\"`\n\tAllowGraphOverride bool                   `yaml:\"allowGraphOverride\"`\n\tAnnotations        *tools.ToolAnnotations `yaml:\"annotations,omitempty\"`\n}\n\n// validate interface\nvar _ tools.ToolConfig = Config{}\n\nfunc (cfg Config) ToolConfigType() string {\n\treturn resourceType\n}\n\nfunc (cfg Config) Initialize(context.Context) (tools.Tool, error) {\n\tif cfg.Description == \"\" {\n\t\treturn nil, fmt.Errorf(\"description is required for tool %q\", cfg.Name)\n\t}\n\n\tcypherParameter := parameters.NewStringParameter(\"cypher\", \"The cypher to execute.\")\n\tdryRunParameter := parameters.NewBooleanParameter(\n\t\t\"dry_run\",\n\t\t\"If set to true, the query will be validated and its execution plan \"+\n\t\t\t\"returned without running the query. Defaults to false.\", parameters.WithBooleanDefault(\n\t\t\tfalse))\n\tparams := parameters.Parameters{cypherParameter, dryRunParameter}\n\tif cfg.AllowGraphOverride {\n\t\tgraphParameter := parameters.NewStringParameter(\n\t\t\t\"graph\",\n\t\t\t\"The name of the graph to query. Defaults to the source's configured graph.\",\n\t\t\tparameters.WithStringDefault(\"\"))\n\t\tparams = append(params, graphParameter)\n\t}\n\n\tdefaultAnnotations := tools.NewDestructiveAnnotations","sourceCodeStart":51,"sourceCodeEnd":87,"githubUrl":"https://github.com/googleapis/mcp-toolbox/blob/8cc6e09de2ad7b8bffc77751799585a1401a48eb/internal/tools/falkordb/falkordbexecutecypher/falkordbexecutecypher.go#L51-L87","documentation":"Config.Initialize for the falkordb-execute-cypher tool requires a non-empty `description` before it will construct the Tool. The description is surfaced in the tool manifest for LLM clients; an empty one makes the tool invalid, so Initialize fails with this error.","triggerScenarios":"Loading config where a `falkordb-execute-cypher` tool lacks a `description` field or has `description: \"\"`.","commonSituations":"Omitting description while copying the dry_run/cypher parameter boilerplate; merge conflicts that dropped the description line; generated configs with blank description templates.","solutions":["Add a non-empty `description` to the falkordb-execute-cypher tool entry","Check the YAML block belongs to the tool and wasn't dropped by a merge","Quote the description so special characters parse safely","Reload the toolbox and confirm the tool registers"],"exampleFix":"// before (tools.yaml)\ntools:\n  exec-cypher:\n    kind: falkordb-execute-cypher\n    source: falkordb\n// after\ntools:\n  exec-cypher:\n    kind: falkordb-execute-cypher\n    source: falkordb\n    description: Executes a Cypher query with optional dry-run plan validation.","handlingStrategy":"validation","validationCode":"if strings.TrimSpace(t.Description) == \"\" {\n    return fmt.Errorf(\"tool %q (falkordb-execute-cypher) is missing description\", t.Name)\n}","typeGuard":"func validToolConfig(cfg Config) bool { return strings.TrimSpace(cfg.Description) != \"\" && cfg.Name != \"\" }","tryCatchPattern":"_, err := cfg.Initialize(ctx)\nif err != nil && strings.Contains(err.Error(), \"description is required\") {\n    return fmt.Errorf(\"add description for tool %s in tools.yaml\", cfg.Name)\n}","preventionTips":["Fill descriptions for execute-style tools immediately, including parameter semantics","Add a config test that Initializes every tool in the default tools.yaml","Quote multi-sentence descriptions and keep them on properly indented lines","Check merge diffs for dropped description lines"],"tags":["go","configuration","validation","yaml"],"backgroundTag":"missing-required-argument","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"}