Open mhjacks opened 5 months ago
If you add a document separator line ---
, it should probably work fine. Still, even this is acceptable, we need to update the messaging to hint plugin authors to make use of that to avoid errors.
The reality is that we assume that the entire EXAMPLES
variable is a valid YAML document. Multiple keys are invalid. WDYT?
I think better hinting would be very helpful, and some explicit notice that EXAMPLES should use document separators if it repeats keys would make this situation much more understandable.
Summary
Running recent ansible-lint in the root of the servicenow.itsm collection repo results in some errors based on documentation that seem normal for documentation and not errors.
Issue Type
OS / ENVIRONMENT
STEPS TO REPRODUCE
Desired Behavior
ansible-lint should not error on the .py file
Actual Behavior
The source code in question can be found at https://raw.githubusercontent.com/ansible-collections/servicenow.itsm/2.6.0/plugins/inventory/now.py
For example, lines 157-209 represent a fairly normal documentation snippet:
ansible-lint fails on the repetition of plugin: and keyed_groups:. I can of course explicitly exclude this file, but maybe it would be better if ansible-lint did not error here?