diff --git a/openstack_auth/utils.py b/openstack_auth/utils.py index 91ac31cb9f..f55847b6ec 100644 --- a/openstack_auth/utils.py +++ b/openstack_auth/utils.py @@ -290,27 +290,6 @@ def _augment_url_with_version(auth_url): return url_path_append(auth_url, "/v2.0") -# TODO(tsufiev): remove this legacy version as soon as Horizon switches to -# the new fix_auth_url_version_prefix() call -def fix_auth_url_version(auth_url): - """Fix up the auth url if an invalid or no version prefix was given. - - People still give a v2 auth_url even when they specify that they want v3 - authentication. Fix the URL to say v3 in this case and add version if it is - missing entirely. This should be smarter and use discovery. - """ - auth_url = _augment_url_with_version(auth_url) - - if get_keystone_version() >= 3 and has_in_url_path(auth_url, ["/v2.0"]): - LOG.warning("The Keystone URL (either in Horizon settings or in " - "service catalog) points to a v2.0 Keystone endpoint, " - "but v3 is specified as the API version to use by " - "Horizon. Using v3 endpoint for authentication.") - auth_url = url_path_replace(auth_url, "/v2.0", "/v3", 1) - - return auth_url - - def fix_auth_url_version_prefix(auth_url): """Fix up the auth url if an invalid or no version prefix was given. diff --git a/releasenotes/notes/remove-fix-auth-url-version-e63c52fbbd293838.yaml b/releasenotes/notes/remove-fix-auth-url-version-e63c52fbbd293838.yaml new file mode 100644 index 0000000000..bf991af8db --- /dev/null +++ b/releasenotes/notes/remove-fix-auth-url-version-e63c52fbbd293838.yaml @@ -0,0 +1,5 @@ +--- +other: + - | + Deprecated function fix_auth_url_version is removed from openstack_auth + library. fix_auth_url_version_prefix function should be used instead of it.