Fix pip args in download CLI (#8287)

This commit is contained in:
Adriane Boyd 2021-06-04 19:02:02 +02:00 committed by GitHub
parent 2c1de4b9a4
commit 22287c89c0
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -128,6 +128,6 @@ def get_version(model, comp):
def download_model(filename, user_pip_args=None):
download_url = about.__download_url__ + "/" + filename
pip_args = user_pip_args if user_pip_args is not None else []
pip_args = list(user_pip_args) if user_pip_args is not None else []
cmd = [sys.executable, "-m", "pip", "install"] + pip_args + [download_url]
return subprocess.call(cmd, env=os.environ.copy())