From 1f3b2f5c8a827d1179356fc1794e8d40fe9227b2 Mon Sep 17 00:00:00 2001 From: imnyang Date: Sun, 15 Jun 2025 22:08:57 +0900 Subject: [PATCH] =?UTF-8?q?[Enhancement]=20=EC=8A=A4=ED=86=A0=EB=A6=AC?= =?UTF-8?q?=EC=A7=80=20=EC=83=81=ED=83=9C=20=EA=B2=BD=EB=A1=9C=20=EC=84=A4?= =?UTF-8?q?=EC=A0=95=20=EB=A1=9C=EC=A7=81=20=EA=B0=9C=EC=84=A0:=20?= =?UTF-8?q?=EC=8A=A4=ED=81=AC=EB=A6=BD=ED=8A=B8=20=EB=94=94=EB=A0=89?= =?UTF-8?q?=ED=86=A0=EB=A6=AC=20=EA=B8=B0=EB=B0=98=EC=9C=BC=EB=A1=9C=20?= =?UTF-8?q?=EC=88=98=EC=A0=95?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- lib/utils/browser_use/func.py | 10 ++++++++-- 1 file changed, 8 insertions(+), 2 deletions(-) diff --git a/lib/utils/browser_use/func.py b/lib/utils/browser_use/func.py index 3f3a93f..f44b2dd 100644 --- a/lib/utils/browser_use/func.py +++ b/lib/utils/browser_use/func.py @@ -22,8 +22,13 @@ def setup_proxy(): def setup_storage_state(): """Setup browser storage state for session persistence.""" - storage_state_path = Path("./data/storage_state.json").resolve() - storage_state_temp_path = Path("./data/storage_state_temp.json").resolve() + # Get the script directory to ensure correct path resolution + script_dir = Path(__file__).parent.parent.parent.parent + storage_state_path = script_dir / "data" / "storage_state.json" + storage_state_temp_path = script_dir / "data" / "storage_state_temp.json" + + print(f"📂 Storage state path: {storage_state_path}") + print(f"📂 Temp storage state path: {storage_state_temp_path}") if storage_state_path.exists(): if storage_state_temp_path.exists(): @@ -35,6 +40,7 @@ def setup_storage_state(): print(f"🔄 Using existing storage state: {storage_state_temp_path}") return str(storage_state_temp_path) + print("⚠️ No existing storage state found") return None