You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@tvm.apache.org by ar...@apache.org on 2022/05/25 23:31:05 UTC
[tvm] 01/01: fixup! Fix all scripts which reference python3 in the docker containers.
This is an automated email from the ASF dual-hosted git repository.
areusch pushed a commit to branch areusch/freeze-dependencies
in repository https://gitbox.apache.org/repos/asf/tvm.git
commit 7b7cc02944d757675d63a062faf427171497db5b
Author: Andrew Reusch <ar...@gmail.com>
AuthorDate: Wed May 25 14:34:27 2022 -0700
fixup! Fix all scripts which reference python3 in the docker containers.
---
tests/scripts/setup-pytest-env.sh | 4 ++--
tests/scripts/task_lint.sh | 5 ++++-
2 files changed, 6 insertions(+), 3 deletions(-)
diff --git a/tests/scripts/setup-pytest-env.sh b/tests/scripts/setup-pytest-env.sh
index 63145c9909..d0a2ab17bb 100755
--- a/tests/scripts/setup-pytest-env.sh
+++ b/tests/scripts/setup-pytest-env.sh
@@ -39,7 +39,7 @@ function cleanup() {
set +x
if [ "${#pytest_errors[@]}" -gt 0 ]; then
echo "These pytest invocations failed, the results can be found in the Jenkins 'Tests' tab or by scrolling up through the raw logs here."
- python3 tests/scripts/pytest_wrapper.py "${pytest_errors[@]}"
+ "${TVM_VENV}/bin/python3" tests/scripts/pytest_wrapper.py "${pytest_errors[@]}"
exit 1
fi
set -x
@@ -59,7 +59,7 @@ function run_pytest() {
suite_name="${test_suite_name}-${ffi_type}"
exit_code=0
- TVM_FFI=${ffi_type} python3 -m pytest \
+ TVM_FFI=${ffi_type} "${TVM_VENV}/bin/python3" -m pytest \
-o "junit_suite_name=${suite_name}" \
"--junit-xml=${TVM_PYTEST_RESULT_DIR}/${suite_name}.xml" \
"--junit-prefix=${ffi_type}" \
diff --git a/tests/scripts/task_lint.sh b/tests/scripts/task_lint.sh
index 8fbba52662..5cc48553b0 100755
--- a/tests/scripts/task_lint.sh
+++ b/tests/scripts/task_lint.sh
@@ -28,6 +28,8 @@ trap cleanup 0
# These shards are solely for CI to enable the lint job to have some parallelism.
function shard1 {
+ . "${TVM_VENV}/bin/activate"
+
echo "Convert scripts to Python..."
tests/scripts/task_convert_scripts_to_python.sh
@@ -57,6 +59,8 @@ function shard1 {
}
function shard2 {
+ . "${TVM_VENV}/bin/activate"
+
echo "Linting the Python code with pylint..."
tests/lint/pylint.sh
@@ -87,4 +91,3 @@ else
shard1
shard2
fi
-