expected_label_op

Diagnostic `nanook::expr::expected_label_op`

Summary

expected label operator

Help

labels match with key="value", key!="value", or key=~"pattern"

Details

When this fires

Inside a label matcher block (the { ... } after a metric), the parser found a key but no operator. Labels match with =, !=, or =~, and an unquoted string value or a missing operator trips this.

What to check

The value must be a quoted string, even for plain text.

# broken
expr = "http.requests{method GET} > 100"
# fixed
expr = "http.requests{method=\"GET\"} > 100"

Caught by nanook check. See @/docs/nanook-expr.md for label-selector syntax.