diff --git a/imperative/python/test/run.sh b/imperative/python/test/run.sh index f8295a75..6132ad74 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 9bfdc265..daa8ba4d 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 `