From 514dbfaa1bbd351a3ff4b5da2b2d10c7c338ea15 Mon Sep 17 00:00:00 2001 From: li <> Date: Fri, 7 Nov 2025 11:39:06 +0800 Subject: [PATCH] feat: add custom_flags --default-background-color --- pixelle_video/services/frame_html.py | 33 ++++++++++++++-------------- 1 file changed, 17 insertions(+), 16 deletions(-) diff --git a/pixelle_video/services/frame_html.py b/pixelle_video/services/frame_html.py index c964ba8..133332d 100644 --- a/pixelle_video/services/frame_html.py +++ b/pixelle_video/services/frame_html.py @@ -313,22 +313,23 @@ class HTMLFrameGenerator: if self.hti is None: # Configure Chrome flags for Linux headless environment custom_flags = [ - # '--no-sandbox', # Bypass AppArmor/sandbox restrictions - # '--disable-dev-shm-usage', # Avoid shared memory issues - # '--disable-gpu', # Disable GPU acceleration - # '--disable-software-rasterizer', # Disable software rasterizer - # '--disable-extensions', # Disable extensions - # '--disable-setuid-sandbox', # Additional sandbox bypass - # '--disable-dbus', # Disable DBus to avoid permission errors - # '--hide-scrollbars', # Hide scrollbars for cleaner output - # '--mute-audio', # Mute audio - # '--disable-background-networking', # Disable background networking - # '--disable-features=TranslateUI', # Disable translate UI - # '--disable-ipc-flooding-protection', # Improve performance - # '--no-first-run', # Skip first run dialogs - # '--no-default-browser-check', # Skip default browser check - # '--disable-backgrounding-occluded-windows', # Improve performance - # '--disable-renderer-backgrounding', # Improve performance + '--default-background-color=00000000', + '--no-sandbox', # Bypass AppArmor/sandbox restrictions + '--disable-dev-shm-usage', # Avoid shared memory issues + '--disable-gpu', # Disable GPU acceleration + '--disable-software-rasterizer', # Disable software rasterizer + '--disable-extensions', # Disable extensions + '--disable-setuid-sandbox', # Additional sandbox bypass + '--disable-dbus', # Disable DBus to avoid permission errors + '--hide-scrollbars', # Hide scrollbars for cleaner output + '--mute-audio', # Mute audio + '--disable-background-networking', # Disable background networking + '--disable-features=TranslateUI', # Disable translate UI + '--disable-ipc-flooding-protection', # Improve performance + '--no-first-run', # Skip first run dialogs + '--no-default-browser-check', # Skip default browser check + '--disable-backgrounding-occluded-windows', # Improve performance + '--disable-renderer-backgrounding', # Improve performance ] # Try to find non-snap browser