[os_tempest][ansible-2.8] (tempest_install_method == 'source'): 'tempest_install_method' is undefined

Bug #1838496 reported by chandan kumar
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
tripleo
Fix Released
High
Unassigned

Bug Description

While updating ansible version in Tripleo Quickstart 's requirements.tx, the os_tempest tripleo job started failing with following error
Logs: http://logs.openstack.org/19/667219/5/check/tripleo-ci-centos-7-standalone/a34fc53/job-output.txt.gz#_2019-07-22_10_35_04_992828
````
2019-07-22 10:35:04.845172 | primary | ok: [undercloud] => {
2019-07-22 10:35:04.845306 | primary | "changed": false
2019-07-22 10:35:04.845363 | primary | }
2019-07-22 10:35:04.845409 | primary |
2019-07-22 10:35:04.845457 | primary | MSG:
2019-07-22 10:35:04.845497 | primary |
2019-07-22 10:35:04.845576 | primary | All assertions passed
2019-07-22 10:35:04.867738 | primary |
2019-07-22 10:35:04.867969 | primary | RUNNING HANDLER [python_venv_build : venv changed] *****************************
2019-07-22 10:35:04.908909 | primary | Monday 22 July 2019 10:35:04 +0000 (0:00:00.127) 1:23:17.409 ***********
2019-07-22 10:35:04.992220 | primary | fatal: [undercloud]: FAILED! => {}
2019-07-22 10:35:04.992325 | primary |
2019-07-22 10:35:04.992378 | primary | MSG:
2019-07-22 10:35:04.992418 | primary |
2019-07-22 10:35:04.992828 | primary | The conditional check 'tempest_install_method == 'source'' failed. The error was: error while evaluating conditional (tempest_install_method == 'source'): 'tempest_install_method' is undefined
2019-07-22 10:35:04.992875 | primary |
2019-07-22 10:35:04.993224 | primary | The error appears to be in '/home/zuul/workspace/.quickstart/usr/local/share/ansible/roles/python_venv_build/handlers/main.yml': line 16, column 3, but may
2019-07-22 10:35:04.993386 | primary | be elsewhere in the file depending on the exact syntax problem.
2019-07-22 10:35:04.993425 | primary |
2019-07-22 10:35:04.993524 | primary | The offending line appears to be:
2019-07-22 10:35:04.993562 | primary |
2019-07-22 10:35:04.993599 | primary |
2019-07-22 10:35:04.993689 | primary | - name: venv changed
2019-07-22 10:35:04.993746 | primary | ^ here
2019-07-22 10:35:04.993786 | primary |
```

Since Tripleo Side, tempest playbook https://opendev.org/openstack/tripleo-quickstart-extras/src/branch/master/playbooks/tempest.yml called here https://opendev.org/openstack/tripleo-quickstart-extras/src/branch/master/playbooks/multinode-standalone.yml#L53

Once the tempest run finishes, python_venv_build noop handler is called and then above error is appearing, based on discussion http://eavesdrop.openstack.org/irclogs/%23openstack-ansible/%23openstack-ansible.2019-07-26.log.html#t2019-07-26T16:50:35

thats where the var tempest_install_method is defined, and it's scope is only for that task
so when the handler runs at the and of the play it fails because the var is not in scope,
moving the defintion of the var up to the vars: section at the top of the play
and then it will be in scope for the whole of the play, including when the handlers run.

Above suggestion fixes the issue.

Tags: tempest
Revision history for this message
chandan kumar (chkumar246) wrote :
Changed in tripleo:
status: Confirmed → Fix Released
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.