deprecation warnings on validate_bool
AxisNL opened this issue · 3 comments
Hey, I just installed a new puppet machine. I'm using module puppetlabs-stdlib (v4.17.1) and saz-timezone (v3.5.0). When trying to set a timezone, I get a deprecation warning:
Warning: This method is deprecated, please use the stdlib validate_legacy function, with Stdlib::Compat::Bool. There is further documentation for validate_legacy function in the README. at ["/etc/puppetlabs/code/environments/production/modules/timezone/manifests/init.pp", 56]:
(at /etc/puppetlabs/code/environments/production/modules/stdlib/lib/puppet/functions/deprecation.rb:25:in `deprecation')
It seems this code:
validate_bool($hwutc)
validate_bool($autoupgrade)
Should be updated to match the newer stdlib behaviour since puppet 3 is deprecated?
edit: this seems to fix the deprecation warnings:
validate_legacy(Boolean, 'validate_bool', $hwutc)
validate_legacy(Boolean, 'validate_bool', $autoupgrade)
There will be version 4 soon 😄