Skip to content

Commit c8e65c5

Browse files
committed
Use same python for subprocesses
1 parent f651714 commit c8e65c5

File tree

1 file changed

+5
-5
lines changed

1 file changed

+5
-5
lines changed

build.py

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -14,8 +14,8 @@
1414
# different from the user's PATH. When building our linux packages on various distros, we want to
1515
# be build machine agnostic, so we redirect python calls to the python we bundle in. Usage of
1616
# these variables can be seen in our build_scripts folder.
17-
PIP = os.getenv('CUSTOM_PIP', 'pip')
18-
PYTHON = os.getenv('CUSTOM_PYTHON', 'python')
17+
18+
PYTHON = os.getenv('CUSTOM_PYTHON', sys.executable)
1919

2020

2121
def print_heading(heading, f=None):
@@ -52,7 +52,7 @@ def build():
5252

5353
# install general requirements.
5454
utility.exec_command(
55-
'{0} install -r requirements-dev.txt'.format(PIP),
55+
'{0} -m pip install -r requirements-dev.txt'.format(PYTHON),
5656
utility.ROOT_DIR)
5757

5858
# convert windows line endings to unix for mssql-cli bash script
@@ -138,8 +138,8 @@ def validate_package():
138138
mssqlcli_wheel_name = [pkge for pkge in mssqlcli_wheel_dir
139139
if current_platform in pkge and 'dev-latest' not in pkge]
140140
utility.exec_command(
141-
'{0} install --no-cache-dir --no-index ./dist/{1}'.format(
142-
PIP,
141+
'{0} -m pip install --no-cache-dir --no-index ./dist/{1}'.format(
142+
PYTHON,
143143
mssqlcli_wheel_name[0]),
144144
root_dir, continue_on_error=False
145145
)

0 commit comments

Comments
 (0)