jamiepine/voicebox · warning · HTTPException

Downloadable CUDA backend releases are currently only…

Error message

Downloadable CUDA backend releases are currently only published for Windows.

What it means

HTTP 409 raised by POST /backend/download-cuda when cuda.get_cuda_download_unsupported_reason() returns a non-None string. That function returns the constant 'Downloadable CUDA backend releases are currently only published for Windows.' on every platform where sys.platform != 'win32' (i.e. Linux and macOS). The prebuilt CUDA backend archive is only published for Windows releases, so the download endpoint refuses on other OSes.

Solutions

  1. Run the download flow only on Windows; on Linux/macOS use a CPU backend or build CUDA support locally.
  2. Gate the UI 'Download CUDA' button on the status payload's download_supported flag (GET /backend/cuda).
  3. If CUDA is required on Linux, provision a GPU node with the CUDA toolkit and run the CUDA server binary directly rather than via this endpoint.

Example fix

// before
await fetch('/backend/download-cuda', { method: 'POST' });
// after
const status = await fetch('/backend/cuda').then(r => r.json());
if (!status.download_supported) { alert(status.unsupported_reason); return; }
await fetch('/backend/download-cuda', { method: 'POST' });
Defensive patterns

Strategy: validation

Validate before calling

const status = await fetch('/backend/cuda').then(r => r.json());
if (!status.download_supported) throw new Error(status.unsupported_reason);

Type guard

function isWindowsDownloadSupported(s): s is { download_supported: true } { return s?.download_supported === true; }

Try / catch

const r = await fetch('/backend/download-cuda', { method:'POST' });
if (r.status === 409) { const { detail } = await r.json(); /* platform / already downloaded / in progress */ }

Prevention

When it happens

Trigger: Calling POST /backend/download-cuda from a Linux or macOS host (or any non-win32 sys.platform).

Common situations: Running the app on Linux/macOS and clicking 'Download CUDA backend' in the UI; a cross-platform deployment that assumes the CUDA backend is universally downloadable; Docker container on a Linux image.

Related errors


AI-assisted analysis of jamiepine/voicebox@51f49dea19 (2026-08-12). Data as JSON: /api/errors/5440be8c91146b98. Report an issue: GitHub.

Appendix: source

Thrown at backend/routes/cuda.py:31

logger = logging.getLogger(__name__)


@router.get("/backend/cuda-status")
async def get_cuda_status():
    """Get CUDA backend download/availability status."""
    from ..services import cuda

    return cuda.get_cuda_status()


@router.post("/backend/download-cuda")
async def download_cuda_backend():
    """Download the CUDA backend binary."""
    from ..services import cuda

    unsupported_reason = cuda.get_cuda_download_unsupported_reason()
    if unsupported_reason:
        raise HTTPException(status_code=409, detail=unsupported_reason)

    if cuda.get_cuda_binary_path() is not None:
        raise HTTPException(status_code=409, detail="CUDA backend already downloaded")

    progress_manager = get_progress_manager()
    existing = progress_manager.get_progress(cuda.PROGRESS_KEY)
    if existing and existing.get("status") == "downloading":
        raise HTTPException(status_code=409, detail="CUDA backend download already in progress")

    async def _download():
        try:
            await cuda.download_cuda_binary()
        except Exception as e:
            logger.error("CUDA download failed: %s", e)

    create_background_task(_download())
    return {"message": "CUDA backend download started", "progress_key": "cuda-backend"}

View on GitHub (pinned to 51f49dea19)