chore(preflight): Use vars lookups - #793
Open
plamerdimak wants to merge 2 commits into
Open
Conversation
When installing the node exporter, the following warning show up:
[DEPRECATION WARNING]: The internal "vars" dictionary is deprecated. This feature will be removed from ansible-core version 2.24.
Origin: /tmp/.ansible/collections/ansible_collections/prometheus/prometheus/roles/_common/tasks/preflight.yml:14:9
12 ansible.builtin.assert:
13 that:
14 - __common_parent_role_short_name ~ '_skip_install' not in vars
^ column 9
[...]
Use the `vars` and `varnames` lookups instead.
Indeed, Ansible advises to use vars lookups for these assertion checks.
Use `vars` lookups.
Link: ansible/ansible#85673
Signed-off-by: Plamerdi Makela <plamerdi447@gmail.com>
vars lookupsvars lookups
Contributor
|
I raised #869 since this had been sitting for a while, but I don't mean to step on something you're already working on, so if you want to get the tests passing on this one we can use yours instead of mine |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Hello,
I noticed this while installing the role.
Thanks for your feedback.
When installing the node exporter, the following warning show up:
Indeed, Ansible advises to use vars lookups for these assertion checks.
Use
varslookups.Link: ansible/ansible#85673