Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix os_quota when volume service not available #57364

Open
wants to merge 1 commit into
base: devel
from

Conversation

Projects
None yet
2 participants
@priteau
Copy link

commented Jun 4, 2019

SUMMARY

os_quota checks the current quotas for compute, network and volume services and fails when no volume service is found in the catalog.

Since openstack test deployments without volume services are common os_quota shouldn't fail if such service is missing.

This was originally fixed in d31a09c and later adapted to catch exceptions raised by shade. Since then, this module moved to using openstacksdk, which doesn't catch the exception raised by keystoneauth1.

Fixes #41240

ISSUE TYPE
  • Bugfix Pull Request
COMPONENT NAME
  • os_quota
ADDITIONAL INFORMATION

Without this commit, setting compute and network quotas on a cloud without volume service results in:

keystoneauth1.exceptions.catalog.EndpointNotFound: public endpoint for block-storage service in RegionOne region not found

With this commit, compute and network quotas are set.

@ansibot

This comment has been minimized.

Copy link
Contributor

commented Jun 4, 2019

The test ansible-test sanity --test import --python 2.6 [explain] failed with 1 error:

lib/ansible/modules/cloud/openstack/os_quota.py:228:0: ImportError: No module named keystoneauth1

The test ansible-test sanity --test import --python 2.7 [explain] failed with 1 error:

lib/ansible/modules/cloud/openstack/os_quota.py:228:0: ImportError: No module named keystoneauth1

The test ansible-test sanity --test import --python 3.5 [explain] failed with 1 error:

lib/ansible/modules/cloud/openstack/os_quota.py:228:0: ImportError: No module named 'keystoneauth1'

The test ansible-test sanity --test import --python 3.6 [explain] failed with 1 error:

lib/ansible/modules/cloud/openstack/os_quota.py:228:0: ModuleNotFoundError: No module named 'keystoneauth1'

The test ansible-test sanity --test import --python 3.7 [explain] failed with 1 error:

lib/ansible/modules/cloud/openstack/os_quota.py:228:0: ModuleNotFoundError: No module named 'keystoneauth1'

The test ansible-test sanity --test import --python 3.8 [explain] failed with 1 error:

lib/ansible/modules/cloud/openstack/os_quota.py:228:0: ModuleNotFoundError: No module named 'keystoneauth1'

The test ansible-test sanity --test validate-modules [explain] failed with 4 errors:

lib/ansible/modules/cloud/openstack/os_quota.py:0:0: E321 Exception attempting to import module for argument_spec introspection, 'No module named 'keystoneauth1''
test/sanity/validate-modules/ignore.txt:175:1: A102 Remove since "lib/ansible/modules/cloud/openstack/os_quota.py" passes "E322" test
test/sanity/validate-modules/ignore.txt:176:1: A102 Remove since "lib/ansible/modules/cloud/openstack/os_quota.py" passes "E323" test
test/sanity/validate-modules/ignore.txt:177:1: A102 Remove since "lib/ansible/modules/cloud/openstack/os_quota.py" passes "E326" test

click here for bot help

@opendev-zuul

This comment has been minimized.

Copy link

commented Jun 4, 2019

Build succeeded (third-party-check pipeline).

@priteau priteau force-pushed the stackhpc:issue-41240 branch from db6a5d1 to c9d2427 Jun 4, 2019

@ansibot ansibot removed the ci_verified label Jun 4, 2019

@ansibot

This comment has been minimized.

Copy link
Contributor

commented Jun 4, 2019

The test ansible-test sanity --test pylint [explain] failed with 1 error:

lib/ansible/modules/cloud/openstack/os_quota.py:234:28: undefined-variable Undefined variable 'traceback'

The test ansible-test sanity --test import --python 2.6 [explain] failed with 1 error:

lib/ansible/modules/cloud/openstack/os_quota.py:234:0: NameError: name 'traceback' is not defined

The test ansible-test sanity --test import --python 2.7 [explain] failed with 1 error:

lib/ansible/modules/cloud/openstack/os_quota.py:234:0: NameError: name 'traceback' is not defined

The test ansible-test sanity --test import --python 3.5 [explain] failed with 1 error:

lib/ansible/modules/cloud/openstack/os_quota.py:234:0: NameError: name 'traceback' is not defined

The test ansible-test sanity --test import --python 3.6 [explain] failed with 1 error:

lib/ansible/modules/cloud/openstack/os_quota.py:234:0: NameError: name 'traceback' is not defined

The test ansible-test sanity --test import --python 3.7 [explain] failed with 1 error:

lib/ansible/modules/cloud/openstack/os_quota.py:234:0: NameError: name 'traceback' is not defined

The test ansible-test sanity --test import --python 3.8 [explain] failed with 1 error:

lib/ansible/modules/cloud/openstack/os_quota.py:234:0: NameError: name 'traceback' is not defined

The test ansible-test sanity --test validate-modules [explain] failed with 4 errors:

lib/ansible/modules/cloud/openstack/os_quota.py:0:0: E321 Exception attempting to import module for argument_spec introspection, 'name 'traceback' is not defined'
test/sanity/validate-modules/ignore.txt:175:1: A102 Remove since "lib/ansible/modules/cloud/openstack/os_quota.py" passes "E322" test
test/sanity/validate-modules/ignore.txt:176:1: A102 Remove since "lib/ansible/modules/cloud/openstack/os_quota.py" passes "E323" test
test/sanity/validate-modules/ignore.txt:177:1: A102 Remove since "lib/ansible/modules/cloud/openstack/os_quota.py" passes "E326" test

click here for bot help

@ansibot ansibot added the ci_verified label Jun 4, 2019

@priteau priteau force-pushed the stackhpc:issue-41240 branch from c9d2427 to dc0d3f9 Jun 4, 2019

@ansibot ansibot removed the ci_verified label Jun 4, 2019

@opendev-zuul

This comment has been minimized.

Copy link

commented Jun 4, 2019

Build succeeded (third-party-check pipeline).

Fix os_quota when volume service not available
os_quota checks the current quotas for compute, network and volume
services and fails when no volume service is found in the catalog.

Since openstack test deployments without volume services are common,
os_quota shouldn't fail if such service is missing.

This was originally fixed in d31a09c
and later adapted to catch exceptions raised by shade. Since then, this
module moved to using openstacksdk, which doesn't catch the exception
raised by keystoneauth1.

Fixes #41240

@priteau priteau force-pushed the stackhpc:issue-41240 branch from dc0d3f9 to 1aca1f2 Jun 5, 2019

@opendev-zuul

This comment has been minimized.

Copy link

commented Jun 5, 2019

Build succeeded (third-party-check pipeline).

@ansibot ansibot added the stale_ci label Jun 13, 2019

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.