Skip to content

Commit 44857ae

Browse files
pip_library: ensure pip_flags is always a string (#314)
When the `pip_flags` parameter and the `PipFlags` plugin configuration option are both undefined, the output of `pip_library` contains the [none](https://pypi.org/project/none/) module as well as the desired one because `None` is erroneously passed as an argument to pip. Ensure `None` is not passed to pip under these circumstances. Fixes #313.
1 parent a18ff0d commit 44857ae

1 file changed

Lines changed: 1 addition & 1 deletion

File tree

build_defs/python.build_defs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -434,7 +434,7 @@ def pip_library(name:str, version:str, labels:list=[], hashes:list=None, package
434434
post_install_commands = post_install_commands or []
435435
use_pypi = CONFIG.PYTHON.USE_PYPI if use_pypi is None else use_pypi
436436
index_flag = '' if use_pypi else '--no-index'
437-
pip_flags = pip_flags or CONFIG.PYTHON.PIP_FLAGS
437+
pip_flags = pip_flags or CONFIG.PYTHON.PIP_FLAGS or ""
438438

439439
repo_flag = ''
440440
repo = repo or CONFIG.PYTHON.DEFAULT_PIP_REPO

0 commit comments

Comments
 (0)