diff --git a/imperative/python/test/run.sh b/imperative/python/test/run.sh index f8295a7574cd68c4ea172a195c5a457e7db0df98..6132ad74e2403d076b75f1251f97eb0d5a496ce8 100755 --- a/imperative/python/test/run.sh +++ b/imperative/python/test/run.sh @@ -42,9 +42,10 @@ else cd $(dirname "${BASH_SOURCE[0]}")/.. test_dirs="megengine test" echo "test develop env" - PYTHONPATH="." PY_IGNORE_IMPORTMISMATCH=1 python3 -m pytest -s -v $test_dirs -m 'not isolated_distributed' + TEST_PY_PATH="." + PYTHONPATH=${TEST_PY_PATH} PY_IGNORE_IMPORTMISMATCH=1 python3 -m pytest -s -v $test_dirs -m 'not isolated_distributed' if [[ "$TEST_PLAT" =~ "cuda" ]]; then echo "test GPU pytest now" - PYTHONPATH="." PY_IGNORE_IMPORTMISMATCH=1 python3 -m pytest -s -v $test_dirs -m 'isolated_distributed' + PYTHONPATH=${TEST_PY_PATH} PY_IGNORE_IMPORTMISMATCH=1 python3 -m pytest -s -v $test_dirs -m 'isolated_distributed' fi fi diff --git a/scripts/whl/BUILD_PYTHON_WHL_README.md b/scripts/whl/BUILD_PYTHON_WHL_README.md index 9bfdc2652d2c076cdb319239c8036a2de7be6bf0..daa8ba4d41e4e6d8449c4f90e9b4c92905bde21e 100755 --- a/scripts/whl/BUILD_PYTHON_WHL_README.md +++ b/scripts/whl/BUILD_PYTHON_WHL_README.md @@ -98,4 +98,4 @@ If you do not want to create whl file when debug Python3 binding, you can call ` * cuda with `RelWithDebInfo` mode: `EXTRA_CMAKE_ARGS="-DCMAKE_BUILD_TYPE=RelWithDebInfo" scripts/cmake-build/host_build.sh -c -t` * cpu only with `RelWithDebInfo` mode: `EXTRA_CMAKE_ARGS="-DCMAKE_BUILD_TYPE=RelWithDebInfo" scripts/cmake-build/host_build.sh -t` -Start `Python3 ` with env for support `MegEngine` after build: `PYTHONPATH=imperative/python:$PYTHONPATH python3 ` +Start `Python3 ` with env for support `MegEngine` after build: `PYTHONPATH=imperative/python:python_module:$PYTHONPATH python3 `