From 7ceaa9a3643595defce5284e6d0c9d4ee2b721f3 Mon Sep 17 00:00:00 2001 From: christian-B Date: Mon, 20 Jul 2026 12:14:58 +0100 Subject: [PATCH 1/2] use venv for mypy --- mypyd.bash | 16 +++++++++++++--- 1 file changed, 13 insertions(+), 3 deletions(-) diff --git a/mypyd.bash b/mypyd.bash index 15336830..84aeb843 100755 --- a/mypyd.bash +++ b/mypyd.bash @@ -14,10 +14,20 @@ # See the License for the specific language governing permissions and # limitations under the License. -# This bash assumes that other repositories are installed in paralled +# This bash assumes that other repositories are installed in parallel -# requires the latest mypy -# pip install --upgrade mypy +if [ "$#" -eq "0" ] + then + echo "Provide any argument to run setup" + source ../SupportScripts/venv/mypy_runner/bin/activate +else + python3 -m venv ../SupportScripts/venv/mypy_runner + source ../SupportScripts/venv/mypy_runner/bin/activate + pip3 install --upgrade ../SpiNNUtils + pip3 install --upgrade ../SpiNNMachine + pip3 install --upgrade ../SpiNNMan + python3 -m pip install --upgrade mypy +fi utils="../SpiNNUtils/spinn_utilities" machine="../SpiNNMachine/spinn_machine" From a04e00fdfefb4d891b97a3fb4130732e9cefc469 Mon Sep 17 00:00:00 2001 From: christian-B Date: Mon, 20 Jul 2026 15:27:43 +0100 Subject: [PATCH 2/2] use venv for mypy --- mypyd.bash | 9 +++------ 1 file changed, 3 insertions(+), 6 deletions(-) diff --git a/mypyd.bash b/mypyd.bash index 84aeb843..db42f40b 100755 --- a/mypyd.bash +++ b/mypyd.bash @@ -18,18 +18,15 @@ if [ "$#" -eq "0" ] then - echo "Provide any argument to run setup" + echo "Using previous setup. Provide an argument to run setup" source ../SupportScripts/venv/mypy_runner/bin/activate else python3 -m venv ../SupportScripts/venv/mypy_runner source ../SupportScripts/venv/mypy_runner/bin/activate pip3 install --upgrade ../SpiNNUtils pip3 install --upgrade ../SpiNNMachine - pip3 install --upgrade ../SpiNNMan + pip3 install --upgrade ../SpiNNMan[test] python3 -m pip install --upgrade mypy fi -utils="../SpiNNUtils/spinn_utilities" -machine="../SpiNNMachine/spinn_machine" - -mypy --disallow-untyped-defs $utils $machine spinnman unittests spinnman_integration_tests +mypy --disallow-untyped-defs spinnman unittests spinnman_integration_tests