From 5e4490495657e0b6809622b90584b07acfef2cec Mon Sep 17 00:00:00 2001 From: James Ketrenos Date: Tue, 9 Sep 2025 14:16:26 -0700 Subject: [PATCH] Fix shared path --- voicebot/set_whisper_debug.py | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/voicebot/set_whisper_debug.py b/voicebot/set_whisper_debug.py index 1aa61ac..77902e4 100644 --- a/voicebot/set_whisper_debug.py +++ b/voicebot/set_whisper_debug.py @@ -8,8 +8,12 @@ import logging import sys import os -# Add the voicebot directory to the path -sys.path.append(os.path.dirname(os.path.abspath(__file__))) +# Add the project root (parent of the voicebot directory) to sys.path so +# imports like `from shared import ...` work when running this script from +# inside the `voicebot` container. +project_root = os.path.dirname(os.path.dirname(os.path.abspath(__file__))) +if project_root not in sys.path: + sys.path.append(project_root) from shared.logger import logger