When we have a reusable role and it had a dependency - the dependency role gets executed with the wrong parameters. #70773
Labels
affects_2.9
This issue/PR affects Ansible v2.9
bug
This issue/PR relates to a bug.
needs_info
This issue requires further information. Please answer any outstanding questions.
needs_template
This issue/PR has an incomplete description. Please fill in the proposed template correctly.
python3
support:core
This issue/PR relates to code supported by the Ansible Engineering Team.
SUMMARY
The latest manual for today for v. 2.9 tells if we pass different parameters to the role - which is declared twice - it would be executed twice. But that does not work for the dependencies.
ISSUE TYPE
ANSIBLE VERSION
CONFIGURATION
OS / ENVIRONMENT
MacOS 10.15.6
STEPS TO REPRODUCE
Set up the role which should be executed several times (saying the role which installs the artifact). This role has a dependency (saying the role which downloads the artifact), which accepts the parameters from the main role as well.
The main role would print the correct values of the parameters, but the dependency role would print the values which we pass at the latest point where we call the main role.
EXPECTED RESULTS
APP_BUILD
in pb-yii-app andpb_down_artifact
in pb-download should be the same.APP_NAME
in pb-yii-app andpb_app_name
in pb-download should be the same.ACTUAL RESULTS
pb-download role which is a dependency of pb-yii-app prints the wrong values of
pb_down_artifact
andpb_app_name
(which is the value at the latest point where we call the role) instead of the values which we pass to the role in themeta/main.yml
file.The text was updated successfully, but these errors were encountered: