fix(lint): actually allow empty YAML values in yamllint config - #124
Merged
Merged
Conversation
The comment in .yamllint says empty values are allowed because they are common in docker-compose files (named volumes, networks), but the rule was set to `enable`. yamllint disables empty-values by default, so `enable` turned the check on and every compose file in the repo reported errors. dev.sh swallows the yamllint exit code, so CI stayed green while GitHub surfaced the errors as failure annotations on unrelated PR diffs. Set the rule to `disable` to match the stated intent, and drop the trailing space on the empty CloudFormation `Default:` value, which was the only non-empty-values finding. Claude-Session: https://claude.ai/code/session_01Ap9Smra9D3ZLPUeKDkDYQJ
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
.yamllintsays empty values should be allowed (named volumes and networks in docker-compose use them), but the rule was set toenable. yamllint disablesempty-valuesby default, soenableturned the check on. Every compose file in the repo reported errors;dev.shswallows the yamllint exit code, so CI stayed green while GitHub attached the errors as failure annotations to unrelated PR diffs (see #123, #122).Change
.yamllint:empty-values: disable, matching the existing comment.CLOUDFORMATION_EXAMPLE.yaml: remove trailing space after the emptyDefault:. This was the only finding not caused by the config.Verification
Same file set as
dev.sh lint(*.yml/*.yaml,.git*paths excluded):empty-valuesplus onetrailing-spaces