diff --git a/install.sh b/install.sh index acc5dee..197590f 100755 --- a/install.sh +++ b/install.sh @@ -55,8 +55,9 @@ print_success "Python gefunden: $PYTHON_VERSION" # Prüfe und installiere python3-venv wenn nötig print_step "Prüfe venv-Installation..." -if ! python3 -c "import venv" 2>/dev/null; then - print_warning "venv ist nicht installiert. Installation wird versucht..." +# Prüfe ob ensurepip verfügbar ist (wird für venv benötigt) +if ! python3 -c "import ensurepip" 2>/dev/null; then + print_warning "ensurepip ist nicht verfügbar. Installation von python3-venv erforderlich..." # Erkenne Distribution if [ -f /etc/debian_version ]; then @@ -84,6 +85,12 @@ if ! python3 -c "import venv" 2>/dev/null; then print_error "Distribution nicht erkannt. Bitte installieren Sie python3-venv manuell." exit 1 fi + + # Verifiziere Installation + if ! python3 -c "import ensurepip" 2>/dev/null; then + print_error "Installation von $VENV_PACKAGE fehlgeschlagen!" + exit 1 + fi print_success "venv installiert" else print_success "venv ist bereits installiert"