{"record":{"id":"c79d42d533e8a985","repo":"gastownhall/beads","slug":"notes-does-not-support-s-operator","errorCode":null,"errorMessage":"notes does not support %s operator","messagePattern":"notes does not support (.+?) operator","errorType":"validation","errorClass":null,"httpStatus":null,"severity":"error","filePath":"internal/query/evaluator.go","lineNumber":900,"sourceCode":"\t\t}, nil\n\tdefault:\n\t\treturn nil, fmt.Errorf(\"description does not support %s operator\", comp.Op.String())\n\t}\n}\n\nfunc (e *Evaluator) buildNotesPredicate(comp *ComparisonNode) (func(*types.Issue) bool, error) {\n\tvalue := strings.ToLower(comp.Value)\n\tswitch comp.Op {\n\tcase OpEquals:\n\t\treturn func(i *types.Issue) bool {\n\t\t\treturn strings.Contains(strings.ToLower(i.Notes), value)\n\t\t}, nil\n\tcase OpNotEquals:\n\t\treturn func(i *types.Issue) bool {\n\t\t\treturn !strings.Contains(strings.ToLower(i.Notes), value)\n\t\t}, nil\n\tdefault:\n\t\treturn nil, fmt.Errorf(\"notes does not support %s operator\", comp.Op.String())\n\t}\n}\n\nfunc (e *Evaluator) buildCreatedPredicate(comp *ComparisonNode) (func(*types.Issue) bool, error) {\n\tt, err := e.parseTimeValue(comp)\n\tif err != nil {\n\t\treturn nil, fmt.Errorf(\"invalid created time: %w\", err)\n\t}\n\treturn e.buildTimePredicate(comp.Op, t, func(i *types.Issue) time.Time { return i.CreatedAt })\n}\n\nfunc (e *Evaluator) buildUpdatedPredicate(comp *ComparisonNode) (func(*types.Issue) bool, error) {\n\tt, err := e.parseTimeValue(comp)\n\tif err != nil {\n\t\treturn nil, fmt.Errorf(\"invalid updated time: %w\", err)\n\t}\n\treturn e.buildTimePredicate(comp.Op, t, func(i *types.Issue) time.Time { return i.UpdatedAt })\n}","sourceCodeStart":882,"sourceCodeEnd":918,"githubUrl":"https://github.com/gastownhall/beads/blob/71377f276968b452ee607177637970a4ff888584/internal/query/evaluator.go#L882-L918","documentation":"The `notes` field supports contains-style matching and NotEquals (both on the lowercased Notes string). Any other operator in a notes comparison reaches the default branch of buildNotesPredicate and returns this error.","triggerScenarios":"A query filter like `notes = \"some note\"` if equality is not handled, or `notes >= foo` — an operator outside the contains/not-equals set.","commonSituations":"Expecting exact-match semantics on notes text; carrying over operators from other text fields; assuming notes are indexed/searchable like full text in other tools.","solutions":["Use the contains operator with a keyword expected in the notes.","Use `!=` to exclude notes containing the text.","For structured lookups, query another field (status, assignee, label) instead of notes."],"exampleFix":"// before\nbd list --query \"notes = escalated\"\n// after\nbd list --query \"notes contains escalated\"","handlingStrategy":"validation","validationCode":"// Go: notes supports contains and != only\nif !isContainsOp(comp.Op) && comp.Op != query.OpNotEquals {\n    return fmt.Errorf(\"notes supports only contains and !=, got %s\", comp.Op)\n}","typeGuard":null,"tryCatchPattern":"// Go\npred, err := e.buildComparisonPredicate(node)\nif err != nil {\n    return fmt.Errorf(\"notes filter invalid: %w\", err)\n}","preventionTips":["Use keyword contains filters on notes, not equality.","Matching is case-insensitive substring; keywords suffice.","Prefer structured fields (status, label, assignee) for reliable filtering."],"tags":["query-language","unsupported-operator","notes"],"backgroundTag":"query-unsupported-operator","analyzedSha":"71377f276968b452ee607177637970a4ff888584","analyzedAt":"2026-08-30T18:55:39.744Z","schemaVersion":2},"datasetVersion":"2026-08-30T23:17:21.991Z"}