Skip to content

Open-source Python library for AI browser agents, plus Browser Use Cloud: stealth browsers and a hosted agent API.

fix

mertunsall74dffc96dc03
diff --git a/examples/custom-functions/save_pdf.py b/examples/custom-functions/save_pdf.py
index 4a28d69bc..92b61fc16 100644
--- a/examples/custom-functions/save_pdf.py
+++ b/examples/custom-functions/save_pdf.py
@@ -18,6 +18,7 @@ from browser_use.llm import ChatOpenAI
controller = Controller()
download_path = Path.cwd() / 'downloads'
+download_path.mkdir(parents=True, exist_ok=True)
# Save PDF - exact copy from original controller function