Skip to content
This repository was archived by the owner on Nov 29, 2023. It is now read-only.

Commit 3ce3fe8

Browse files
author
Doug Hellmann
committed
Improve error message for missing endpoint
Horizon logs an error when it wants an endpoint that the client can't find, but the error does not say which endpoint is missing. This change includes more details in the error message to make debugging from the horizon logs easier. Change-Id: I6f0aacd469500238f13a2178a220268d86d31fe5 Signed-off-by: Doug Hellmann <doug.hellmann@dreamhost.com>
1 parent 58cb347 commit 3ce3fe8

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

keystoneclient/service_catalog.py

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -77,7 +77,8 @@ def url_for(self, attr=None, filter_value=None,
7777
if not filter_value or endpoint.get(attr) == filter_value:
7878
return endpoint[endpoint_type]
7979

80-
raise exceptions.EndpointNotFound('Endpoint not found.')
80+
raise exceptions.EndpointNotFound('%s endpoint for %s not found.' %
81+
(endpoint_type, service_type))
8182

8283
def get_endpoints(self, service_type=None, endpoint_type=None):
8384
"""Fetch and filter endpoints for the specified service(s).

0 commit comments

Comments
 (0)