Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

validate_legacy() is deprecated from stdlib #879

Open
alaunay opened this issue Dec 28, 2023 · 0 comments
Open

validate_legacy() is deprecated from stdlib #879

alaunay opened this issue Dec 28, 2023 · 0 comments

Comments

@alaunay
Copy link

alaunay commented Dec 28, 2023

Hello,

puppetlabs-stdlib deprecate'd the validate_legacy in 9.0.0 back in May. Thus, the current wazuh-puppet 4.7.1 produces an error when using it with a >=9.0.0 stdlib:

Error: Could not retrieve catalog from remote server: Error 500 on SERVER: Server Error: Evaluation Error: Error while evaluating a Function Call, deprecation. validate_legacy. This method is deprecated, please use Puppet data types to validate parameters at ["/etc/puppetlabs/code/environments/production/modules/wazuh/manifests/agent.pp", 255] (file: /etc/puppetlabs/code/environments/production/modules/wazuh/manifests/agent.pp, line: 255, column: 3) on node XXX

It's used quite a few times in the source:

wazuh-puppet $ grep -r validate_legacy | wc -l
17

Reference:
puppetlabs/puppetlabs-stdlib#1352

It could probably be replace with is_a:
https://github.com/puppetlabs/puppetlabs-stdlib/blob/main/REFERENCE.md#is_a

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant