Closed raoulbhatia closed 3 years ago
Well that might fix it, but your error is not supposed to happen (i.e. $::augeasversion
being undef).
I am still hitting this error with Ubuntu 18.04 and Puppet 5.4.0-2ubuntu3. Any way that I can better debug this?
Ok, it seems that $::augeasversion
is undef
/not set if augeas-tools
is not installed.
It should not require augeas-tools
, only the Augeas library.
The problem is with Facter 3.x, the C implementation runs "augparse --version" to find the version instead of using the Ruby library. The old Ruby implementation works just fine without augeas-tools installed. One possible workaround is to include that implementation as a plugin fact...
Tested on Ubuntu Bionic with facter 3.10.0-4
hi,
I've changed the line https://github.com/camptocamp/puppet-augeas/blob/8e605057c0b3f45b4cf36b13e1ad292fc3b63b88/manifests/lens.pp#L61
from:
if (!$stock_since or versioncmp($::augeasversion, $stock_since) < 0) {
to:
if (!$stock_since or versioncmp("${::augeasversion}", $stock_since) < 0) {
than the problem disapears.
cu denny
The proposed patch worked for me.
I"m seeing this same issue on a Debian Buster install, and the proposed patch fixes it.
Presumably this isn't merged because of the failing ci test:
manifests/lens.pp - WARNING: string containing only a variable on line 61
Is there something that can be done to fix the test or is there a different/better way to solve the problem?
Actually, we should use String()
now: https://puppet.com/docs/puppet/7.5/typecasting.html
This will also fix the linting issue
Thanks for improving my PR! 🇨ðŸ‡
Thanks, this works for me. Can we do a forge release?
Fixes: