Windows Troubleshooting

← Back to Windows Installation

If the standard steps on the Windows installation page don’t work, walk through the checklist below in PowerShell. It was confirmed working with Python 3.12.

  1. Open PowerShell and go to the JuSPICE project folder. This must be the folder containing pyproject.toml:

    cd PATH\TO\juspice
    

    Replace PATH\TO\juspice with the actual location of the juspice folder on your computer. You can check that you are in the correct folder with:

    Test-Path .\pyproject.toml
    

    It should return:

    True
    
  2. Check whether Python 3.12 is available:

    py -0p
    

    JuSPICE worked with Python 3.12.

  3. Install uv if the uv command is not recognized:

    py -3.14 -m pip install --user --upgrade uv
    

    Then locate uv.exe:

    Get-ChildItem "$env:APPDATA\Python" -Recurse -Filter uv.exe -ErrorAction SilentlyContinue
    

    Define its path automatically:

    $uv = Get-ChildItem "$env:APPDATA\Python" -Recurse -Filter uv.exe | Select-Object -First 1 -ExpandProperty FullName
    

    Check that it works:

    & $uv --version
    
  4. Install Python 3.12 using uv:

    & $uv python install 3.12
    
  5. Create a virtual environment with Python 3.12, inside the repository so the checkout stays fully self-contained:

    & $uv venv venvs\.venv --python 3.12
    

    If this fails with a path-related error (rare, but possible with deeply nested checkouts combined with long package names from the [dl] extra), enable Windows long-path support once, as Administrator, then retry:

    New-ItemProperty -Path "HKLM:\SYSTEM\CurrentControlSet\Control\FileSystem" `
        -Name "LongPathsEnabled" -Value 1 -PropertyType DWORD -Force
    
  6. Activate the virtual environment:

    venvs\.venv\Scripts\Activate.ps1
    

    After activation, (.venv) should appear at the beginning of the PowerShell line, for example:

    (.venv) PS C:\...\juspice>
    
  7. Confirm that the activated environment uses Python 3.12:

    python --version
    

    It should show something like:

    Python 3.12.x
    
  8. Install JuSPICE from the project folder:

    & $uv pip install -e .
    
  9. Verify the installation:

    python -c "import juspice; print(juspice.__version__)"
    

    This should print the installed version, for example:

    0.1.0
    

See also