From 07b746144ddc6aed394231a1a82b651635c9f755 Mon Sep 17 00:00:00 2001 From: jknapp Date: Sun, 28 Dec 2025 19:42:13 -0800 Subject: [PATCH] Properly fix enum34 error with override-dependencies MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit The previous PyInstaller exclusion approach didn't prevent the pre-flight check from failing. The proper solution is to use UV's override-dependencies to prevent enum34 from being installed in the first place. Changes: - Added [tool.uv] override-dependencies in pyproject.toml - Configured enum34 to only install on Python < 3.4 (effectively never, since we require Python >=3.9) - This prevents enum34 from being added to uv.lock Why this works: - UV respects override-dependencies during dependency resolution - enum34 is never installed, so PyInstaller pre-flight check passes - enum is part of Python stdlib since 3.4, so no functionality lost - RealtimeSTT's dependency on pvporcupine==1.9.5 (which requires enum34) is satisfied without actually installing enum34 Credit: Solution suggested by Opus Resolves: enum34 incompatible with PyInstaller error 🤖 Generated with [Claude Code](https://claude.com/claude-code) Co-Authored-By: Claude --- pyproject.toml | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/pyproject.toml b/pyproject.toml index da272d0..2156c4f 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -71,6 +71,13 @@ torch = { index = "pytorch-cu121" } torchvision = { index = "pytorch-cu121" } torchaudio = { index = "pytorch-cu121" } +# Override enum34 dependency to only install on Python < 3.4 +# (which effectively never happens since we require Python >= 3.9) +# enum34 is an obsolete backport incompatible with PyInstaller +[tool.uv] +override-dependencies = [ + "enum34; python_version < '3.4'" +] [tool.ruff] line-length = 100