Browse code

Add workaround for openstacksdk in check_libs_from_git

python-openstacksdk does not match its pip name which is openstacksdk.
So setting python-openstacksdk in LIBS_FROM_GIT leads to devstack
thinking there is a problem.

Put in a workaround for now. It would be better to either:

a) rename python-openstacksdk repo to openstacksdk
b) rename the pip name for openstacksdk back to python-openstacksdk
c) add general support in the various GIT hashes for a pip name

Change-Id: I57cf95763d54ad2060a4ce2af91c3ba18ca04db0

Monty Taylor authored on 2017/12/04 01:21:26
Showing 1 changed files
... ...
@@ -407,6 +407,12 @@ function use_library_from_git {
407 407
 function lib_installed_from_git {
408 408
     local name=$1
409 409
     local safe_name
410
+    # TODO(mordred) This is a special case for python-openstacksdk, where the
411
+    # repo name and the pip name do not match. We should either add systemic
412
+    # support for providing aliases, or we should rename the git repo.
413
+    if [[ $name == 'python-openstacksdk' ]] ; then
414
+        name=openstacksdk
415
+    fi
410 416
     safe_name=$(python -c "from pkg_resources import safe_name; \
411 417
         print(safe_name('${name}'))")
412 418
     # Note "pip freeze" doesn't always work here, because it tries to