From 99460a804352eef67a12af9266b44b9ac2590f10 Mon Sep 17 00:00:00 2001 From: "alexei.dolgolyov" Date: Thu, 2 Apr 2026 14:22:18 +0300 Subject: [PATCH] fix: make pystray a core dependency on Windows instead of optional extra The tray icon should always appear on Windows, not only when installed with the [tray] extra. --- INSTALLATION.md | 1 - build-dist.ps1 | 2 +- server/pyproject.toml | 6 ++---- 3 files changed, 3 insertions(+), 6 deletions(-) diff --git a/INSTALLATION.md b/INSTALLATION.md index 3bd92c0..4ba9c10 100644 --- a/INSTALLATION.md +++ b/INSTALLATION.md @@ -123,7 +123,6 @@ Screen capture from inside a container requires X11 access. Uncomment `network_m ```bash pip install ".[perf]" # DXCam, BetterCam, WGC (Windows only) pip install ".[notifications]" # OS notification capture - pip install ".[tray]" # System tray icon (Windows only) pip install ".[dev]" # pytest, black, ruff (development) ``` diff --git a/build-dist.ps1 b/build-dist.ps1 index 733a9f8..8b3357b 100644 --- a/build-dist.ps1 +++ b/build-dist.ps1 @@ -130,7 +130,7 @@ if ($LASTEXITCODE -ne 0) { throw "Failed to install pip" } # ── Install dependencies ────────────────────────────────────── Write-Host "[5/8] Installing dependencies..." -$extras = "camera,notifications,tray" +$extras = "camera,notifications" if (-not $SkipPerf) { $extras += ",perf" } # Install the project (pulls all deps via pyproject.toml), then remove diff --git a/server/pyproject.toml b/server/pyproject.toml index 5687e14..05afd56 100644 --- a/server/pyproject.toml +++ b/server/pyproject.toml @@ -48,6 +48,8 @@ dependencies = [ "opencv-python-headless>=4.8.0", "websockets>=13.0", "just-playback>=0.1.7", + "pystray>=0.19.0; sys_platform == 'win32'", + "Pillow>=10.4.0; sys_platform == 'win32'", ] [project.optional-dependencies] @@ -80,10 +82,6 @@ perf = [ "bettercam>=1.0.0; sys_platform == 'win32'", "windows-capture>=1.5.0; sys_platform == 'win32'", ] -tray = [ - "pystray>=0.19.0; sys_platform == 'win32'", - "Pillow>=10.4.0; sys_platform == 'win32'", -] [project.urls] Homepage = "https://git.dolgolyov-family.by/alexei.dolgolyov/wled-screen-controller-mixed"