From 924b6c8867618deb4cb8534069e82293b0eac588 Mon Sep 17 00:00:00 2001 From: VAliquo <vincentaliquo@gmail.com> Date: Mon, 16 Dec 2024 14:55:31 -0500 Subject: [PATCH] [UPDATE] Clean up Windows Ollama installation --- install/local_model.py | 19 +++---------------- 1 file changed, 3 insertions(+), 16 deletions(-) diff --git a/install/local_model.py b/install/local_model.py index f95a3b7..afe561e 100644 --- a/install/local_model.py +++ b/install/local_model.py @@ -67,25 +67,12 @@ def install_ollama() -> bool: print("Please complete the Ollama installation. Once done, type 'c' and press Enter to continue.") while input("Type 'c' to continue: ").strip().lower() != 'c': print("Invalid input. Please type 'c' to continue.") - - # Verify the installation - print("Verifying Ollama installation...") - result = subprocess.run( - ["ollama", "--version"], - capture_output=True, - text=True, - ) - - if result.returncode == 0: - print(f"Ollama installed successfully: {result.stdout.strip()}") - else: - print("Ollama installation verification failed!") - print("stderr:", result.stderr.strip()) - return False else: print("Unsupported platform for Ollama installation.") return False - + if not ollama_installed(): + print("Oh dear, something went wrong installing Ollama.") + return False print("Ollama installation succeeded!") return True except subprocess.CalledProcessError as e: -- GitLab