rodjek / puppet-lint

Check that your Puppet manifests conform to the style guide
MIT License
820 stars 204 forks source link

Wrong warrning: "variable contains an uppercase" #929

Closed shamil closed 3 years ago

shamil commented 4 years ago

I've this peace of code:

$test = "${Integer(fact('memory.system.total_bytes') * 0.7)}b"

puppet-lint prints warning about Integer has an uppercase, but Integrer is not variable it's a function for typecasting.

The error I get:

modules/profile/manifests/puppet-lint-test.pp - WARNING: variable contains an uppercase letter on line 3

Currently to avoid having this warning I use sprintf, but prefer to avoid it if possible:

$test = sprintf('%db', Integer(fact('memory.system.total_bytes') * 0.7))