From 7b1f318916268a20ecbdf44143ac48c08c6f5386 Mon Sep 17 00:00:00 2001 From: Daniel Bedeleanu Date: Sat, 18 Apr 2026 13:40:30 +0000 Subject: [PATCH] fix: improve venv creation with error checking and proper validation --- start_server.sh | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/start_server.sh b/start_server.sh index bf9e6605..c3ae1cfe 100755 --- a/start_server.sh +++ b/start_server.sh @@ -24,11 +24,12 @@ pkill -f "next-server" || true pkill -f "local-ssl-proxy" || true # 2. Setup/Activate Virtual Environment -if [ ! -d ".venv" ]; then +if [ ! -f ".venv/bin/activate" ]; then echo "🌑 Creating virtual environment (.venv)..." - python3 -m venv .venv + rm -rf .venv + python3 -m venv .venv || { echo "❌ Failed to create venv"; exit 1; } fi -source .venv/bin/activate +source .venv/bin/activate || { echo "❌ Failed to activate venv"; exit 1; } # 3. Check and Install Backend Dependencies echo "📦 Updating Python dependencies..."