Error running cfn-lint with pipe (|)
See original GitHub issuecfn-lint version: v0.23.0
Hello we have a problem running cfn-lint with find command. Only this version is affected as far as we know. We are keeping couple of template is a folder and linting them like that:
find ./templates -type f | xargs cfn-lint -f parseable -c I -t
It worked flawlessly before but with the new update we are getting this error:
2019-08-02 15:37:01,818 - cfnlint.decode - ERROR - Template file not found: None None:1:1:1:2:E0000:Template file not found: None
Splitting the files in separated lines with xargs -L 1
doesn’t help.
If you run the cfn-lint command on it’s own it works as expected.
This example doesn’t work:
find ./templates -type f | xargs -t cfn-lint -f parseable -c I -t
cfn-lint -f parseable -c I -t ./templates/t1.yml ./templates/t2.yml ./templates/t3.yml
2019-08-02 15:50:20,891 - cfnlint.decode - ERROR - Template file not found: None
None:1:1:1:2:E0000:Template file not found: None
This example works:
cfn-lint -f parseable -c I -t ./templates/t1.yml ./templates/t2.yml ./templates/t3.yml
Regards TT
Issue Analytics
- State:
- Created 4 years ago
- Comments:9 (4 by maintainers)
Top Results From Across the Web
Error running cfn-lint with pipe (|) · Issue #1080 - GitHub
Hello we have a problem running cfn-lint with find command. Only this version is affected as far as we know. We are keeping...
Read more >cfn-lint failing while validating Cloudformation templates
I had cfn-lint as part of my Jenkins pipeline setup everytime a build has been triggered. It validates the CloudFormation templates on ...
Read more >cfn-lint - PyPI
For each level of discovered error cfn-lint will use bitwise OR to ... From a command prompt run cfn-lint <path to template> to...
Read more >CDK Pipelines and CloudFormation linting - Oblivion
Cfn-lint is the CloudFormation Linter tool. ... to a repository and on pull request a pipeline will run and execute the code ......
Read more >CFN Lint: AWS CloudFormation Linter - Morioh
AWS CloudFormation Linter, Validate AWS CloudFormation yaml/json templates against the AWS CloudFormation Resource Specification and additional checks.
Read more >
Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free
Top Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
@ns-cweber this fix does appear to work for your use case too. Added a test to prevent this from happening again. Should have a fix out shortly.
Thanks a lot guys I can confirm
works like a charm, we will use it now instead of
find
.