fuel2 env delete fails

Bug #1467510 reported by Ilya Kharin
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
Fuel for OpenStack
Fix Released
High
Roman Prykhodchenko
6.1.x
Won't Fix
High
Unassigned

Bug Description

The fuel2 client fails each time when I try to delete an environment.

1. Create an environment:

    # fuel2 env create -r 37 -n neutron -nst vlan just-new

2. Delete the newly created environment:

    # fuel2 env delete 5

3. You will get an error (in the debug mode):

      File "/usr/lib/python2.6/site-packages/cliff/app.py", line 280, in run_subcommand
        result = cmd.run(parsed_args)
      File "/usr/lib/python2.6/site-packages/cliff/command.py", line 50, in run
        self.take_action(parsed_args)
      File "/usr/lib/python2.6/site-packages/fuelclient/commands/environment.py", line 125, in take_action
        if env.status == 'operational' and not parsed_args.force:
    AttributeError: 'dict' object has no attribute 'status'
    Traceback (most recent call last):
      File "/usr/bin/fuel2", line 10, in <module>
        sys.exit(main())
      File "/usr/lib/python2.6/site-packages/fuelclient/cli/error.py", line 98, in wrapper
        return func(*args, **kwargs)
      File "/usr/lib/python2.6/site-packages/fuelclient/main.py", line 76, in main
        return fuelclient_app.run(argv)
      File "/usr/lib/python2.6/site-packages/cliff/app.py", line 215, in run
        result = self.run_subcommand(remainder)
      File "/usr/lib/python2.6/site-packages/cliff/app.py", line 280, in run_subcommand
        result = cmd.run(parsed_args)
      File "/usr/lib/python2.6/site-packages/cliff/command.py", line 50, in run
        self.take_action(parsed_args)
      File "/usr/lib/python2.6/site-packages/fuelclient/commands/environment.py", line 125, in take_action
        if env.status == 'operational' and not parsed_args.force:
    AttributeError: 'dict' object has no attribute 'status'

Ilya Kharin (akscram)
summary: - fuel2 env delete failed
+ fuel2 env delete fails
Changed in fuel:
status: New → Confirmed
importance: Undecided → High
assignee: nobody → Roman Prykhodchenko (romcheg)
milestone: none → 7.0
Revision history for this message
Roman Prykhodchenko (romcheg) wrote :

My concern is about targeting this to 7.0. The new client stops working in one of its major scenarios, sounds like a critical problem which has to be fixed in 6.1.

The solution is relatively simple: one line of a code is screwed up, so the fix is simple and easy. The bigger problem is that this particular bug was not detected because mocking of the client-library is done wrong. To fix that problem it's necessary to introduce plenty of similar changes to v2/cli tests to ensure, the same problem won't appear in a different place.

There is a workaround for this bug which is to use the old CLI, i. e., fuel, not fuel2.

Revision history for this message
Tomasz 'Zen' Napierala (tzn) wrote :

We will release update through pypi channel

tags: added: release-notes
Changed in fuel:
status: Confirmed → In Progress
Changed in fuel:
status: In Progress → Fix Committed
tags: added: on-verification
Revision history for this message
Alexander Arzhanov (aarzhanov) wrote :

Verified on ISO #164:

api: '1.0'
astute_sha: e1d3a435e5df5b40cbfb1a3acf80b4176d15a2dc
auth_required: true
build_id: 2015-08-12_15-16-47
build_number: '164'
feature_groups:
- mirantis
fuel-agent_sha: 57145b1d8804389304cd04322ba0fb3dc9d30327
fuel-library_sha: 22f848670e49d89fc04aaed4d8efd1b07360cbe7
fuel-nailgun-agent_sha: e01693992d7a0304d926b922b43f3b747c35964c
fuel-ostf_sha: 58220583f10fa47f12291488ef77854809c68310
fuelmain_sha: 67e5214c0dc5d4ba6da4ae651cef9934800459a9
nailgun_sha: fff6bda090fac15c48b27cca7832a70f8e381101
openstack_version: 2015.1.0-7.0
production: docker
python-fuelclient_sha: 26fc025e0fc5791b62e5ed8561a6016bf8a406bc
release: '7.0'
release_versions:
  2015.1.0-7.0:
    VERSION:
      api: '1.0'
      astute_sha: e1d3a435e5df5b40cbfb1a3acf80b4176d15a2dc
      build_id: 2015-08-12_15-16-47
      build_number: '164'
      feature_groups:
      - mirantis
      fuel-agent_sha: 57145b1d8804389304cd04322ba0fb3dc9d30327
      fuel-library_sha: 22f848670e49d89fc04aaed4d8efd1b07360cbe7
      fuel-nailgun-agent_sha: e01693992d7a0304d926b922b43f3b747c35964c
      fuel-ostf_sha: 58220583f10fa47f12291488ef77854809c68310
      fuelmain_sha: 67e5214c0dc5d4ba6da4ae651cef9934800459a9
      nailgun_sha: fff6bda090fac15c48b27cca7832a70f8e381101
      openstack_version: 2015.1.0-7.0
      production: docker
      python-fuelclient_sha: 26fc025e0fc5791b62e5ed8561a6016bf8a406bc
      release: '7.0'

Changed in fuel:
status: Fix Committed → Fix Released
tags: removed: on-verification
Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Related fix proposed to fuel-docs (master)

Related fix proposed to branch: master
Review: https://review.openstack.org/223471

Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Related fix merged to fuel-docs (master)

Reviewed: https://review.openstack.org/223471
Committed: https://git.openstack.org/cgit/stackforge/fuel-docs/commit/?id=c3da2eb5f2921abe9b45854f3644baf7e000af9f
Submitter: Jenkins
Branch: master

commit c3da2eb5f2921abe9b45854f3644baf7e000af9f
Author: evkonstantinov <email address hidden>
Date: Tue Sep 15 11:04:05 2015 +0300

    Add fuel2 env delete resolved issue to relnotes

    Change-Id: Idc9354374f3528d6de23434cc9c92d0d4932efba
    Related-Bug:#1467510

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.