diff options
author | Zuul <zuul@review.opendev.org> | 2020-06-03 09:18:20 +0000 |
---|---|---|
committer | Gerrit Code Review <review@openstack.org> | 2020-06-03 09:18:20 +0000 |
commit | fa839516e52b6a2418f48489d106e9931640b2cd (patch) | |
tree | 15c5ef0fca7fd6f7e22f5806b8e3f6512d2a2fef | |
parent | 29af0d34c1d49f2fed566bde939496cc7143e3dd (diff) | |
parent | df92b1113d6e00af05b5f06d0c10a39875bbbde6 (diff) | |
download | horizon-fa839516e52b6a2418f48489d106e9931640b2cd.tar.gz |
Merge "Give keystoneauth1.ClientException only 1 argument (message)" into stable/train16.2.0
-rw-r--r-- | openstack_auth/tests/unit/test_auth.py | 2 | ||||
-rw-r--r-- | openstack_dashboard/api/keystone.py | 4 | ||||
-rw-r--r-- | openstack_dashboard/dashboards/identity/domains/tables.py | 2 |
3 files changed, 4 insertions, 4 deletions
diff --git a/openstack_auth/tests/unit/test_auth.py b/openstack_auth/tests/unit/test_auth.py index a668f2a7f..60a4a0786 100644 --- a/openstack_auth/tests/unit/test_auth.py +++ b/openstack_auth/tests/unit/test_auth.py @@ -376,7 +376,7 @@ class OpenStackAuthTestsV3(OpenStackAuthTestsMixin, def test_exception(self): user = self.data.user form_data = self.get_form_data(user) - exc = keystone_exceptions.ClientException(500) + exc = keystone_exceptions.ClientException('error 500') self._mock_client_password_auth_failure(user.name, user.password, exc) self.mox.ReplayAll() diff --git a/openstack_dashboard/api/keystone.py b/openstack_dashboard/api/keystone.py index af3d779ba..d1600b2fe 100644 --- a/openstack_dashboard/api/keystone.py +++ b/openstack_dashboard/api/keystone.py @@ -440,7 +440,7 @@ def user_update(request, user, **data): if not keystone_can_edit_user(): raise keystone_exceptions.ClientException( - 405, _("Identity service does not allow editing user data.")) + _("Identity service does not allow editing user data.")) try: user = manager.update(user, **data) except keystone_exceptions.Conflict: @@ -458,7 +458,7 @@ def user_update_password(request, user, password, admin=True): if not keystone_can_edit_user(): raise keystone_exceptions.ClientException( - 405, _("Identity service does not allow editing user password.")) + _("Identity service does not allow editing user password.")) manager = keystoneclient(request, admin=admin).users manager.update(user, password=password) diff --git a/openstack_dashboard/dashboards/identity/domains/tables.py b/openstack_dashboard/dashboards/identity/domains/tables.py index 8c0dbf725..7fb879f96 100644 --- a/openstack_dashboard/dashboards/identity/domains/tables.py +++ b/openstack_dashboard/dashboards/identity/domains/tables.py @@ -116,7 +116,7 @@ class DeleteDomainsAction(tables.DeleteAction): msg = _('Domain "%s" must be disabled before it can be deleted.') \ % domain.name messages.error(request, msg) - raise keystoneclient_exceptions.ClientException(409, msg) + raise keystoneclient_exceptions.ClientException(msg) else: LOG.info('Deleting domain "%s".', obj_id) api.keystone.domain_delete(request, obj_id) |