diff --git a/yamllint/rules/anchors.py b/yamllint/rules/anchors.py index befb8b43..83f29db2 100644 --- a/yamllint/rules/anchors.py +++ b/yamllint/rules/anchors.py @@ -159,7 +159,7 @@ def check(conf, token, prev, next, nextnext, context): if not info['used']: yield LintProblem(info['line'] + 1, info['column'] + 1, - f"found unused anchor {anchor}") + f'found unused anchor "{anchor}"') elif isinstance(token, yaml.AliasToken): context['anchors'].get(token.value, {})['used'] = True