aristanetworks / ansible-cvp

Ansible modules for Arista CloudVision
http://cvp.avd.sh
Apache License 2.0
66 stars 61 forks source link

Refactor: relax the condition to raise exception for inline vault password #533

Closed gmuloc closed 1 year ago

gmuloc commented 1 year ago

Some issues (unrelated to this piece of code) have demonstrated that it is necessary to actually relax the test to check if tools_cv.py receives an encrypted VAULT password.

Btw this should happen less and less because ansible has fixed the issue in all train in: https://github.com/ansible/ansible/pull/78236

Change Summary

Rather than raising if the password is not a string, raise only if the password is a dict that containt the __ansible_vault key. More specific and better.

Fix the documentation to reflect that this should not be an issue anymore in recent versions of ansible.

Update the error message as well

Component(s) name

arista.cvp.plugins

Proposed changes

Cf summary changes

How to test

Run the test suite one test added

Checklist

Repository Checklist