-
Notifications
You must be signed in to change notification settings - Fork 31
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
Fix tomcat_version variable usage #97
Fix tomcat_version variable usage #97
Conversation
In the "Download & Extract Tomcat" task we try to detect if the tomcat version to install is the same as the configured in the variables. The check used the literal `tomcat_version` instead of interpolating the Jinja2 value like `{{ tomcat_version }}`.
OK, "draft" is not what I thought. Setting to Ready for review but adding WIP to the title. |
Hi @agimenez thanks for noticing this missbehaviour, I've verified the mentioned issues. |
We were executing the download and extract task if the currently installed version was the same as the wanted one. This fixes the condition, and only executes the task if versions are different, as intended.
@vicsufer branch updated with the comparison fix. Thanks! |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM! 🚀
Description of the Change
In the "Download & Extract Tomcat" task we try to detect if the tomcat
version to install is the same as the configured in the variables.
The check used the literal
tomcat_version
instead ofinterpolating the Jinja2 value like
{{ tomcat_version }}
.NOTE: this opens a new changelog "Fixed" section as well as #96. I will set this as draft as it would cause conflicts on merge. If the other PR is merged in, I will rebase this branch against the latest develop to avoid conflicts.
Benefits
The check that tries to figure out whether the installed Tomcat is the wanted version in the
tomcat_version
variable should work as expected.Possible Drawbacks
TBH, I'm not sure how this was working before. I guess that the particular version check was yelding
false
always.Also, if I understand correctly, the check should be
!=
instead of==
, since I believe that this task will download & install if the installed version is different from the one we want. Is that right? In such case, I can fix the conditional as well.Applicable Issues
N/A