# Set OpenClaw Python to fixed version # This ensures OpenClaw uses Python 3.14.2 regardless of pyenv changes $OpenclawPythonPath = "F:\pyenv\pyenv-win\pyenv-win\versions\3.14.2\python.exe" # Check if Python exists if (Test-Path $OpenclawPythonPath) { Write-Host "Setting OpenClaw Python to: $OpenclawPythonPath" -ForegroundColor Green # Set for current session [System.Environment]::SetEnvironmentVariable("OPENCLAW_PYTHON", $OpenclawPythonPath, "Process") $env:OPENCLAW_PYTHON = $OpenclawPythonPath # Set for user (permanent) [System.Environment]::SetEnvironmentVariable("OPENCLAW_PYTHON", $OpenclawPythonPath, "User") Write-Host "OpenClaw Python version:" -ForegroundColor Cyan & $OpenclawPythonPath --version Write-Host "Environment variable OPENCLAW_PYTHON has been set permanently." -ForegroundColor Yellow Write-Host "OpenClaw will now use Python 3.14.2 for all skill executions." -ForegroundColor Yellow } else { Write-Host "Error: Python not found at $OpenclawPythonPath" -ForegroundColor Red Write-Host "Please check if Python 3.14.2 is installed." -ForegroundColor Red }