diff --git a/openshorts/telegram_bot.py b/openshorts/telegram_bot.py index af47911..bf70778 100644 --- a/openshorts/telegram_bot.py +++ b/openshorts/telegram_bot.py @@ -237,7 +237,11 @@ async def process_video(bot, url: str): env = os.environ.copy() env["NEXTCLOUD_TARGET"] = target env["PYTHONUNBUFFERED"] = "1" + # CRITICAL: Remove PYTHONPATH so the system protobuf doesn't conflict with + # the venv's protobuf used by mediapipe → fixes 'SymbolDatabase.GetPrototype' crash + env.pop("PYTHONPATH", None) log.info(f"[process] Temp output dir: {temp_output}") + log.info(f"[process] PYTHONPATH cleared from subprocess env (mediapipe safety)") # 4. Build command — main.py MUST run with the viral venv Python cmd = [