Allow tools/install_venv_common.py to be run from within the source directory.
(Copy latest update from oslo) Not doing this raised exceptions when it tried importing modules that didn't exist in the path. Fixes LP# 1112484 Change-Id: I2be7bde0bf873a22318617b987a76b209caef22a
This commit is contained in:
parent
894fdb074e
commit
87b1cdc164
@ -25,6 +25,12 @@ import os
|
||||
import subprocess
|
||||
import sys
|
||||
|
||||
possible_topdir = os.getcwd()
|
||||
if os.path.exists(os.path.join(possible_topdir, "cinder",
|
||||
"__init__.py")):
|
||||
sys.path.insert(0, possible_topdir)
|
||||
|
||||
|
||||
from cinder.openstack.common import cfg
|
||||
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user