queens undercloud upgrade fails when overcloud is deployed and validation is enabled

Bug #1832637 reported by Alex Schultz
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
tripleo
Fix Released
High
Alex Schultz

Bug Description

https://review.opendev.org/#/c/657572/ introduced a change to try and fetch the stack name, however the reference to the stack name is incorrect so running openstack undercloud upgrade fails with:

2019-06-12 15:06:36,979 DEBUG: An exception occurred
Traceback (most recent call last):
  File "/usr/lib/python2.7/site-packages/instack_undercloud/undercloud.py", line 2442, in install
    _run_validation_groups(["post-upgrade"], mistral_url)
  File "/usr/lib/python2.7/site-packages/instack_undercloud/undercloud.py", line 1953, in _run_validation_groups
    stack_names_list = [stack['stack_name'] for stack in heat.stacks.list()]
TypeError: 'Stack' object has no attribute '__getitem__'
2019-06-12 15:06:36,979 ERROR:
#############################################################################
Undercloud upgrade failed.

Reason: 'Stack' object has no attribute '__getitem__'

See the previous output for details about what went wrong. The full install
log can be found at /home/cloud-user/.instack/install-undercloud.log.

#############################################################################

NOTE: this only affects rocky and queens usages of instack-undercloud

Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix proposed to instack-undercloud (stable/rocky)

Fix proposed to branch: stable/rocky
Review: https://review.opendev.org/665005

Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix proposed to instack-undercloud (stable/queens)

Fix proposed to branch: stable/queens
Review: https://review.opendev.org/665006

Changed in tripleo:
status: Triaged → In Progress
assignee: nobody → Alex Schultz (alex-schultz)
Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix merged to instack-undercloud (stable/queens)

Reviewed: https://review.opendev.org/665006
Committed: https://git.openstack.org/cgit/openstack/instack-undercloud/commit/?id=0238882ec9da60c55c2cd52c16af7df97adc12f9
Submitter: Zuul
Branch: stable/queens

commit 0238882ec9da60c55c2cd52c16af7df97adc12f9
Author: Alex Schultz <email address hidden>
Date: Wed Jun 12 13:32:46 2019 -0600

    Fix stack_name reference

    The correct way to get the stack name from a stack object is to use
    .stack_name and not ['stack_name']. The current version of this code
    will fail since Stack does not have a __getitem__ implementation.

    Change-Id: I92420af2ca34f1c66058213cbb1a4403017790d1
    Closes-Bug: #1832637
    (cherry picked from commit e2dd051205e93b63774b1e9214f6b5468cb7a178)

tags: added: in-stable-queens
Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix merged to instack-undercloud (stable/rocky)

Reviewed: https://review.opendev.org/665005
Committed: https://git.openstack.org/cgit/openstack/instack-undercloud/commit/?id=e2dd051205e93b63774b1e9214f6b5468cb7a178
Submitter: Zuul
Branch: stable/rocky

commit e2dd051205e93b63774b1e9214f6b5468cb7a178
Author: Alex Schultz <email address hidden>
Date: Wed Jun 12 13:32:46 2019 -0600

    Fix stack_name reference

    The correct way to get the stack name from a stack object is to use
    .stack_name and not ['stack_name']. The current version of this code
    will fail since Stack does not have a __getitem__ implementation.

    Change-Id: I92420af2ca34f1c66058213cbb1a4403017790d1
    Closes-Bug: #1832637

tags: added: in-stable-rocky
Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix included in openstack/instack-undercloud 8.4.8

This issue was fixed in the openstack/instack-undercloud 8.4.8 release.

Changed in tripleo:
status: In Progress → Fix Released
Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix included in openstack/instack-undercloud 9.5.1

This issue was fixed in the openstack/instack-undercloud 9.5.1 release.

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.