@minded-ai/mindedjs 2.0.28 → 2.0.29
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
|
@@ -85,7 +85,11 @@ class ScreenshotCapture:
|
|
|
85
85
|
|
|
86
86
|
# Take screenshot - browser-use takes viewport by default
|
|
87
87
|
# Set timeout to prevent hanging (30 seconds)
|
|
88
|
-
|
|
88
|
+
try:
|
|
89
|
+
screenshot_data = await asyncio.wait_for(page.screenshot(), timeout=30)
|
|
90
|
+
except asyncio.TimeoutError:
|
|
91
|
+
logger.warning(f"⏱️ Screenshot #{step_number} timed out after 30 seconds, skipping...")
|
|
92
|
+
return
|
|
89
93
|
|
|
90
94
|
# Ensure we have bytes - browser-use might return base64 string or bytes
|
|
91
95
|
if isinstance(screenshot_data, bytes):
|
package/package.json
CHANGED
|
@@ -85,7 +85,11 @@ class ScreenshotCapture:
|
|
|
85
85
|
|
|
86
86
|
# Take screenshot - browser-use takes viewport by default
|
|
87
87
|
# Set timeout to prevent hanging (30 seconds)
|
|
88
|
-
|
|
88
|
+
try:
|
|
89
|
+
screenshot_data = await asyncio.wait_for(page.screenshot(), timeout=30)
|
|
90
|
+
except asyncio.TimeoutError:
|
|
91
|
+
logger.warning(f"⏱️ Screenshot #{step_number} timed out after 30 seconds, skipping...")
|
|
92
|
+
return
|
|
89
93
|
|
|
90
94
|
# Ensure we have bytes - browser-use might return base64 string or bytes
|
|
91
95
|
if isinstance(screenshot_data, bytes):
|