From 72b4e29859d9628e5216a214377cd6f3745498c0 Mon Sep 17 00:00:00 2001 From: Matthew Brett Date: Sat, 11 Nov 2023 10:08:30 +0000 Subject: [PATCH] Add tomli, ensure virtualenv --- travis_linux_steps.sh | 4 +++- travis_osx_steps.sh | 3 ++- travis_steps.sh | 6 ++++++ 3 files changed, 11 insertions(+), 2 deletions(-) diff --git a/travis_linux_steps.sh b/travis_linux_steps.sh index 866f18d5..c768bc3c 100644 --- a/travis_linux_steps.sh +++ b/travis_linux_steps.sh @@ -19,10 +19,12 @@ MB_PYTHON_VERSION=${MB_PYTHON_VERSION:-$TRAVIS_PYTHON_VERSION} function before_install { # Install a virtualenv to work in. + python -m pip install virtualenv virtualenv --python=$PYTHON_EXE venv source venv/bin/activate python --version # just to check - pip install --upgrade pip wheel + # Tomli for wheel parsing. + pip install --upgrade pip wheel tomli } function build_wheel { diff --git a/travis_osx_steps.sh b/travis_osx_steps.sh index 784f1a24..722eb535 100644 --- a/travis_osx_steps.sh +++ b/travis_osx_steps.sh @@ -39,7 +39,8 @@ function before_install { get_macpython_environment $MB_PYTHON_VERSION venv source venv/bin/activate - pip install --upgrade pip wheel + # Tomli for wheel parsing. + pip install --upgrade pip wheel tomli } # build_wheel function defined in common_utils (via osx_utils) diff --git a/travis_steps.sh b/travis_steps.sh index 10374cb8..773183fd 100644 --- a/travis_steps.sh +++ b/travis_steps.sh @@ -1,4 +1,10 @@ #!/bin/bash +# Despite the name, this file is not specific to Travis-CI. +# It sets up the local environment for wheel building and testing. +# For Mac, configure xcode, and set up before_install and other +# functions to wrap builds. +# For linux, set up before_install to work in virtualenv, and set up wrapping +# to run build and tests in docker containers. WHEEL_SDIR=${WHEEL_SDIR:-wheelhouse}