runtests.sh issues on Windows machine #313
Replies: 6 comments
-
Currently it not supported on windows... (kind of same as monai.. not sure it supports the similar functionality on windows..) However you can try this: https://docs.microsoft.com/en-us/windows/wsl/install-win10 and then https://www.microsoft.com/en-gb/p/ubuntu-2004-lts/9n6svws3rx71?rtc=1&activetab=pivot:overviewtab |
Beta Was this translation helpful? Give feedback.
-
Doesn't the Python launcher take care of this? https://www.python.org/dev/peps/pep-0397/ |
Beta Was this translation helpful? Give feedback.
-
Currently the bash script runtest.sh is not completely tested on windows.. this is more of a development or ci/cd script.. otherwise you can still run some of the py-checks directly without the help of script.. for example..
|
Beta Was this translation helpful? Give feedback.
-
I will give this a try. |
Beta Was this translation helpful? Give feedback.
-
pytype is not supported on windows However added few basic code format and flake check: But for now the most recommended for running static checks in ubuntu or use WSL on windows |
Beta Was this translation helpful? Give feedback.
-
The pre-commit integration will solve this problem and it's os independent. |
Beta Was this translation helpful? Give feedback.
-
A few issues were experienced running the runtests.sh script locally on a Windows machine:
Line 59 of runtests.sh is causing issue. Python executable on Windows machine is typically called python.exe, rather than python3.exe. I'm using the miniconda install of python 3.7.11. Workaround was to change line 59 to "PY_EXE=${MONAILABEL_PY_EXE:-$(which python)". Other workaround would be to create a python3.exe by duplicating the existing python.exe I think. Is there a solution that works across all OS?
While running ./runtests.sh --autofix, experienced import error for dataclasses package (torch dependency). Cause was use of python 3.6.x (does not support dataclasses). Fix was to create a new virtual env with python 3.7.11. Any suggestion on how to ensure other Windows users don't face the same issue?
While running ./runtests.sh --codeformat, get error "Failed to build pytype". Pytype not supported on Windows (https://github.com/google/pytype). Is there any alternative to Pytype?
Thanks!
Beta Was this translation helpful? Give feedback.
All reactions