All CentOS 7 ovb jobs are failing with SyntaxError: invalid syntax while creating stack

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

Bug Description

All C7 branches ovb jobs are failing while creating stack with RETRY_LIMIT

https://logserver.rdoproject.org/openstack-regular/opendev.org/openstack/tripleo-ci/master/tripleo-ci-centos-7-ovb-3ctlr_1comp-featureset001-stein-branch/ea8c80f/job-output.txt

```
 TASK [ovb-manage : Create a stack]
2021-03-28 22:27:27.958138 | primary | File "/home/zuul/workspace/ovb/openstack-virtual-baremetal/bin/deploy.py", line 248
2021-03-28 22:27:27.958334 | primary | print('Waiting for stack to complete', end="")
2021-03-28 22:27:27.958392 | primary | ^
2021-03-28 22:27:27.958431 | primary | SyntaxError: invalid syntax
2021-03-28 22:27:38.500352 | primary | ERROR
2021-03-28 22:27:38.500621 | primary | {
2021-03-28 22:27:38.500667 | primary | "delta": "0:00:00.019007",
2021-03-28 22:27:38.500696 | primary | "end": "2021-03-28 22:27:27.960184",
2021-03-28 22:27:38.500722 | primary | "msg": "non-zero return code",
2021-03-28 22:27:38.500751 | primary | "rc": 1,
2021-03-28 22:27:38.500778 | primary | "start": "2021-03-28 22:27:27.941177"
2021-03-28 22:27:38.500803 | primary | }
2021-03-28 22:27:38.591849 |
2021-03-28 22:27:38.591967 | TASK [ovb-manage : Show last stack status]
2021-03-28 22:27:41.058684 | primary | Stack not found: baremetal_61429
2021-03-28 22:27:41.203173 | primary | ok: Runtime: 0:00:02.046703
2021-03-28 22:27:41.293271 |
2021-03-28 22:27:41.293391 | TASK [ovb-manage : Delete CREATE_FAILED stack]
2021-03-28 22:27:51.916033 | primary | ERROR
2021-03-28 22:27:51.916356 | primary | {
2021-03-28 22:27:51.916416 | primary | "msg": "The conditional check '\"CREATE_FAILED\" in result.stdout' failed. The error was: error while evaluating conditional (\"CREATE_FAILED\" in result.stdout): Unable to look up a name or access an attribute in template string ({% if \"CREATE_FAILED\" in result.stdout %} True {% else %} False {% endif %}).\nMake sure your variable name does not contain invalid characters like '-': argument of type 'AnsibleUndefined' is not iterable\n\nThe error appears to be in '/var/lib/zuul/builds/ea8c80f7b57343bf8648aee76a7f04c9/trusted/project_0/review.rdoproject.org/config/roles/ovb-manage/tasks/ovb-create-stack.yml': line 151, column 7, but may\nbe elsewhere in the file depending on the exact syntax problem.\n\nThe offending line appears to be:\n\n\n - name: Delete CREATE_FAILED stack\n ^ here\n"
2021-03-28 22:27:51.916474 | primary | }
2021-03-28 22:27:51.939579 |
2021-03-28 22:27:51.939694 | PLAY RECAP
```

Since the C7 branches uses python2 and
print('Waiting for stack to complete', end="") end is not supported in print method in python2.

It all happend due to a upgrade of ovb/stable-2.0 branches. https://review.opendev.org/c/openstack/tripleo-ci/+/782011

By adding from __future__ import print_function in the ovb codebase will fix the issue.

Revision history for this message
Rabi Mishra (rabi) wrote :

We probably should have a centos7 job gating with tripleo-ci to avoid these issues.

Revision history for this message
chandan kumar (chkumar246) wrote :

https://review.rdoproject.org/r/c/config/+/32885 will add the remaining coverage. Since all the related issues are fixed now, and https://review.opendev.org/c/openstack/openstack-virtual-baremetal/+/783597 is merged now, SO closing this bug.

Changed in tripleo:
status: Triaged → 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.