Tempest Volume deleted twice causing error on second delete
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
tempest |
Invalid
|
Undecided
|
Lukáš Piwowarski |
Bug Description
Tempest Volume deleted twice causing error on second delete
Ignore not found error when the volume id deleted second time.
For example in this test:
https:/
On spanshot create the snapshot is added for class level clean up:
Create snapshot
https:/
addClassResourc
https:/
Delete snapshot is called in the test case:
https:/
Class level clean up throws an exception since the volume is deleted:
Captured traceback:
~~~~~~~~~~~~~~~~~~~
Traceback (most recent call last):
File "/home/
six.
File "/usr/local/
raise value
File "/home/
teardown()
File "/home/
raise testtools.
testtools.
Details: {'code': 400, 'message': 'Invalid volume: Volume status must be available or error or error_restoring or error_extending or error_managing and must not be migrating, attached, belong to a group, have snapshots or be disassociated from snapshots after volume transfer.'}, <traceback object at 0x7f37d0504b48>)
Propose fixed.
Remove volume/snapshot delete call in the testcase
description: | updated |
description: | updated |
Changed in tempest: | |
assignee: | nobody → Lukáš Piwowarski (piwowarl) |
Changed in tempest: | |
status: | New → Incomplete |
I think that the deletion of the snapshot should be removed from the test you mention. However, after looking at the code I think that this particular error might be caused by something else. What leads me to this idea is that:
- tempest waits for successful deletion of each snapshot [1] and
- tempest receives NotFound error from Openstack api that is ignored when it tries
to delete a snapshot that does not exist [2].
But I could be wrong. Can you please provide steps of how to reproduce the error to make sure that the double deletion of snapshots is really the cause of the error? (e.g.: Which tests did you run when this error occurred? Did you run only the test_snapshot_ create_ get_list_ update_ delete you mention in the description?)
[1] https:/ /github. com/openstack/ tempest/ blob/3e12764065 7b294c9d4a941b6 a6bb287aa496539 /tempest/ api/volume/ base.py# L182 /github. com/openstack/ tempest/ blob/3e12764065 7b294c9d4a941b6 a6bb287aa496539 /tempest/ lib/common/ utils/test_ utils.py# L88
[2] https:/