Skip to content

Commit

Permalink
fix unbound log_path
Browse files Browse the repository at this point in the history
  • Loading branch information
LawyZheng committed Nov 2, 2024
1 parent ad0bd0b commit bdf4891
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion skyvern/webeye/browser_factory.py
Original file line number Diff line number Diff line change
Expand Up @@ -43,8 +43,8 @@ def get_download_dir(workflow_run_id: str | None, task_id: str | None) -> str:

def set_browser_console_log(browser_context: BrowserContext, browser_artifacts: BrowserArtifacts) -> None:
if browser_artifacts.browser_console_log_path is None:
log_path = f"{settings.LOG_PATH}/{datetime.utcnow().strftime('%Y-%m-%d')}/{uuid.uuid4()}.log"
try:
log_path = f"{settings.LOG_PATH}/{datetime.utcnow().strftime('%Y-%m-%d')}/{uuid.uuid4()}.log"
os.makedirs(os.path.dirname(log_path), exist_ok=True)
# create the empty log file
with open(log_path, "w") as _:
Expand Down

0 comments on commit bdf4891

Please sign in to comment.