clear_validation_resources fails with SecurityGroupInUse

Bug #1979052 reported by Balazs Gibizer
8
This bug affects 1 person
Affects Status Importance Assigned to Milestone
tempest
Fix Released
Undecided
Unassigned

Bug Description

Test are started failing yesterday on the gate with:

Traceback (most recent call last):
  File "/opt/stack/new/tempest/.tox/tempest/lib/python3.8/site-packages/fixtures/fixture.py", line 125, in cleanUp
    return self._cleanups(raise_errors=raise_first)
  File "/opt/stack/new/tempest/.tox/tempest/lib/python3.8/site-packages/fixtures/callmany.py", line 89, in __call__
    reraise(error[0], error[1], error[2])
  File "/opt/stack/new/tempest/.tox/tempest/lib/python3.8/site-packages/testtools/compat.py", line 27, in reraise
    raise exc_obj.with_traceback(exc_tb)
  File "/opt/stack/new/tempest/.tox/tempest/lib/python3.8/site-packages/fixtures/callmany.py", line 83, in __call__
    cleanup(*args, **kwargs)
  File "/opt/stack/new/tempest/tempest/lib/common/validation_resources.py", line 346, in clear_validation_resources
    raise has_exception
  File "/opt/stack/new/tempest/tempest/lib/common/validation_resources.py", line 315, in clear_validation_resources
    security_group_client.delete_security_group(sec_id)
  File "/opt/stack/new/tempest/tempest/lib/services/network/security_groups_client.py", line 59, in delete_security_group
    return self.delete_resource(uri)
  File "/opt/stack/new/tempest/tempest/lib/services/network/base.py", line 42, in delete_resource
    resp, body = self.delete(req_uri)
  File "/opt/stack/new/tempest/tempest/lib/common/rest_client.py", line 330, in delete
    return self.request('DELETE', url, extra_headers, headers, body)
  File "/opt/stack/new/tempest/tempest/lib/common/rest_client.py", line 711, in request
    self._error_checker(resp, resp_body)
  File "/opt/stack/new/tempest/tempest/lib/common/rest_client.py", line 832, in _error_checker
    raise exceptions.Conflict(resp_body, resp=resp)
tempest.lib.exceptions.Conflict: Conflict with state of target resource
Details: {'type': 'SecurityGroupInUse', 'message': 'Security Group 40f249d7-9c4e-432c-91d7-d68ef7ac05b0 in use.', 'detail': ''}

Example run: https://zuul.opendev.org/t/openstack/build/c7b5440bdfc34eff944ddcd1cc923b96/logs

It seems we have some ordering issue in the clear_validation_resources call. Recently we added validation resources to may test cases so [1] might be related.

[1] https://review.opendev.org/c/openstack/tempest/+/817772/8/tempest/api/compute/admin/test_live_migration.py

Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix proposed to tempest (master)

Fix proposed to branch: master
Review: https://review.opendev.org/c/openstack/tempest/+/846251

Changed in tempest:
status: New → In Progress
Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Change abandoned on tempest (master)

Change abandoned by "Martin Kopec <email address hidden>" on branch: master
Review: https://review.opendev.org/c/openstack/tempest/+/846251
Reason: abandoning as it's not needed anymore

Revision history for this message
Martin Kopec (mkopec) wrote :
Changed in tempest:
status: In Progress → Fix Released
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers