From 709daeca63708bd5bc8eda0a1b5a77cedc564d92 Mon Sep 17 00:00:00 2001 From: Christopher Anderson Date: Sat, 9 Aug 2025 04:49:15 +1000 Subject: [PATCH] A better fix for numpy. --- fixnumpy.bat | 17 ++++++++++++----- 1 file changed, 12 insertions(+), 5 deletions(-) diff --git a/fixnumpy.bat b/fixnumpy.bat index b9b27b338..ea6395760 100644 --- a/fixnumpy.bat +++ b/fixnumpy.bat @@ -1,6 +1,13 @@ @echo off -call venv\scripts\activate -pip uninstall numpy -y --quiet -pip install numpy==1.26.4 --quiet -echo numpy 1.26.4 reinstalled. -pause +:: Install numpy silently +venv\Scripts\pip install --force-reinstall "numpy<2" --quiet + +:: Check if installation was successful +if %ERRORLEVEL% neq 0 ( + echo Error: Failed to install numpy + exit /b 1 +) + +:: Display version information +venv\Scripts\python -c "import numpy; print(f'numpy {numpy.__version__} reinstalled.')" +pause \ No newline at end of file