Image upload fails - AttributeError: 'function' object has no attribute 'list'

Bug #1869736 reported by Harald Jensås
14
This bug affects 2 people
Affects Status Importance Assigned to Milestone
tripleo
Fix Released
Critical
Harald Jensås

Bug Description

python3-tripleoclient-13.1.1-0.20200328032410.0379179.el8.noarch
tripleo-ansible-1.2.1-0.20200327193910.2c9551a.el8.noarch

source /home/centos/stackrc
cd /home/centos/images
openstack overcloud image upload
Exception occured while running the command
Traceback (most recent call last):
  File \"/usr/lib/python3.6/site-packages/tripleoclient/command.py\", line 34, in run
      super(Command, self).run(parsed_args)
  File \"/usr/lib/python3.6/site-packages/osc_lib/command/command.py\", line 41, in run
      return super(Command, self).run(parsed_args)
  File \"/usr/lib/python3.6/site-packages/cliff/command.py\", line 187, in run
      return_code = self.take_action(parsed_args) or 0
  File \"/usr/lib/python3.6/site-packages/tripleoclient/v1/overcloud_image.py\", line 553, in take_action
      disk_format='aki'
  File \"/usr/lib/python3.6/site-packages/tripleoclient/v1/overcloud_image.py\", line 371, in update_or_upload
      updated_image = self._image_try_update(glance_name, file_path)
  File \"/usr/lib/python3.6/site-packages/tripleoclient/v1/overcloud_image.py\", line 313, in _image_try_update
      image = self._get_image(image_name)
  File \"/usr/lib/python3.6/site-packages/tripleoclient/v1/overcloud_image.py\", line 294, in _get_image
      image = utils.find_resource(self.client.images, name)
  File \"/usr/lib/python3.6/site-packages/osc_lib/utils/__init__.py\", line 280, in find_resource
      for resource in manager.list():
  AttributeError: 'function' object has no attribute 'list'
  'function' object has no attribute 'list'

Revision history for this message
Harald Jensås (harald-jensas) wrote :

I think the manager, i.e client is'nt correct?
<bound method Proxy.images of <openstack.image.v2._proxy.Proxy object at 0x7f8cba8a4b00>>

Changed in tripleo:
importance: High → Critical
Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix proposed to python-tripleoclient (master)

Fix proposed to branch: master
Review: https://review.opendev.org/716277

Changed in tripleo:
assignee: nobody → Rabi Mishra (rabi)
status: Triaged → In Progress
Revision history for this message
Cédric Jeanneret (cjeanner) wrote :

This is also seen in the promotion jobs.

Apparently you're using the tripleo-ci-testing repository instead of current-tripleo - are you using my tripleo-lab thing? If so, it was using that testing repo since there weren't any promotion for centos-8 back then.

tags: added: promotion-blocker
Revision history for this message
Harald Jensås (harald-jensas) wrote :

I am using repos[1], according to the docs[2] this "The option below will enable the latest master TripleO packages, the latest promoted packages for all other OpenStack services and dependencies". I'm just following the docs.

[1] https://github.com/hjensas/ooo-ipv6-testing/blob/master/playbooks/deploy_undercloud.yaml#L73
[2] https://docs.openstack.org/project-deploy-guide/tripleo-docs/latest/deployment/install_undercloud.html

Changed in tripleo:
assignee: Rabi Mishra (rabi) → Harald Jensås (harald-jensas)
Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix merged to python-tripleoclient (master)

Reviewed: https://review.opendev.org/716277
Committed: https://git.openstack.org/cgit/openstack/python-tripleoclient/commit/?id=62c43e76262a80904a564a71eee256725cca9fc5
Submitter: Zuul
Branch: master

commit 62c43e76262a80904a564a71eee256725cca9fc5
Author: Rabi Mishra <email address hidden>
Date: Tue Mar 31 17:52:04 2020 +0530

    Fix GlanceClientAdapter to use new osc release

    It seems osc has started using openstacksdk[1] and it probably breaks
    how you find image with name.

    [1] https://review.opendev.org/#/c/650374/

    Change-Id: Ia15a065c908aa9992747f5286f2404a0947f6720
    Closes-Bug: #1869736

Changed in tripleo:
status: In Progress → Fix Released
Revision history for this message
Marios Andreou (marios-b) wrote :

also seen there

         * https://logserver.rdoproject.org/96/25796/13/check/tripleo-ci-centos-8-ovb-3ctlr_1comp_1supp-featureset039/0ea37c2/logs/undercloud/home/zuul/overcloud_prep_images.log.txt.gz
        * 2020-04-01 15:53:47 | AttributeError: 'function' object has no attribute 'list'
2020-04-01 15:53:47 | 'function' object has no attribute 'list'

Revision history for this message
John Fulton (jfulton-org) wrote :

The fix to this bug (1869736) seems to have caused https://bugs.launchpad.net/tripleo/+bug/1871181

Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix included in openstack/python-tripleoclient 13.2.0

This issue was fixed in the openstack/python-tripleoclient 13.2.0 release.

To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Duplicates of this bug

Other bug subscribers

Remote bug watches

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