Skip to content

Commit 2f12528

Browse files
chore: dynamic python version adjustments
1 parent f48b950 commit 2f12528

File tree

1 file changed

+7
-7
lines changed

1 file changed

+7
-7
lines changed

.github/workflows/reusable-build-test-release.yml

Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -491,16 +491,16 @@ jobs:
491491
git config --global --add url."https://${{ secrets.GH_TOKEN_ADMIN }}@github.com".insteadOf ssh://git@github.com
492492
python${{ env.PYTHON_VERSION }} -m venv .dev_venv
493493
echo "Found requirements_dev.txt. Installing dev dependencies in an isolated environment"
494-
./.dev_venv/bin/python -m pip install -r dev_deps/requirements_dev.txt
495-
./.dev_venv/bin/python -m pip install -r package/lib/requirements.txt
494+
./.dev_venv/bin/python${{ env.PYTHON_VERSION }} -m pip install -r dev_deps/requirements_dev.txt
495+
./.dev_venv/bin/python${{ env.PYTHON_VERSION }} -m pip install -r package/lib/requirements.txt
496496
- name: Create directories
497497
run: |
498498
mkdir -p /opt/splunk/var/log/splunk
499499
chmod -R 777 /opt/splunk/var/log/splunk
500500
- name: Copy pytest ini
501501
run: cp tests/unit/pytest-ci.ini pytest.ini
502502
- name: Run Pytest with coverage
503-
run: ./.dev_venv/bin/python -m pytest --cov=./ --cov-report=xml --junitxml=test-results/junit.xml tests/unit
503+
run: ./.dev_venv/bin/python${{ env.PYTHON_VERSION }} -m pytest --cov=./ --cov-report=xml --junitxml=test-results/junit.xml tests/unit
504504
- name: Job summary
505505
continue-on-error: true
506506
run: |
@@ -576,7 +576,7 @@ jobs:
576576
if [ -f "dev_deps/requirements_ucc.txt" ]; then
577577
python${{ env.PYTHON_VERSION }} -m venv .ucc_venv
578578
echo "Found requirements_ucc.txt. Installing UCC dependencies in an isolated environment"
579-
./.ucc_venv/bin/python -m pip install -r dev_deps/requirements_ucc.txt
579+
./.ucc_venv/bin/python${{ env.PYTHON_VERSION }} -m pip install -r dev_deps/requirements_ucc.txt
580580
export UCC_GEN="$PWD/.ucc_venv/bin/ucc-gen"
581581
582582
if [ ! -f "$UCC_GEN" ]; then
@@ -609,7 +609,7 @@ jobs:
609609
run: |
610610
git config --global --add url."https://${{ secrets.GH_TOKEN_ADMIN }}@github.com".insteadOf https://github.com
611611
git config --global --add url."https://${{ secrets.GH_TOKEN_ADMIN }}@github.com".insteadOf ssh://git@github.com
612-
pip install -r dev_deps/requirements_dev.txt
612+
python${{ env.PYTHON_VERSION }} -m pip install -r dev_deps/requirements_dev.txt
613613
- name: Semantic Release Get Next
614614
id: semantic
615615
if: github.event_name != 'pull_request'
@@ -902,7 +902,7 @@ jobs:
902902
env:
903903
PYTHON_KEYRING_BACKEND: keyring.backends.null.Keyring
904904
run: |
905-
pip install -r dev_deps/requirements_dev.txt
905+
python${{ env.PYTHON_VERSION }} -m pip install -r dev_deps/requirements_dev.txt
906906
if [ -f "tests/ucc_modinput_functional/tmp/openapi.json" ]; then
907907
ucc-test-modinput gen -o tests/ucc_modinput_functional/tmp/openapi.json -t ${{ steps.download-openapi.outputs.download-path }}/tmp/
908908
else
@@ -917,7 +917,7 @@ jobs:
917917
run: |
918918
python${{ env.PYTHON_VERSION }} -m venv .dev_venv
919919
echo "Found requirements_dev.txt. Installing dev dependencies in an isolated environment"
920-
./.dev_venv/bin/python -m pip install -r dev_deps/requirements_dev.txt
920+
./.dev_venv/bin/python${{ env.PYTHON_VERSION }} -m pip install -r dev_deps/requirements_dev.txt
921921
libs_archive=libs_$(basename "$BUILD_NAME" .spl).tgz
922922
cp -r ./.dev_venv/lib/python${{ env.PYTHON_VERSION }}/site-packages/ libs/
923923
tar -czf "$libs_archive" libs

0 commit comments

Comments
 (0)