Spaces:
Sleeping
Sleeping
duck3-create Claude Opus 4.6 commited on
Commit ·
3eee3bb
1
Parent(s): 50a91ab
Fix Chromium crash in Docker: add --no-sandbox and --disable-dev-shm-usage
Browse files
main.py
CHANGED
|
@@ -434,7 +434,10 @@ def _extract_ig_video_url(url):
|
|
| 434 |
|
| 435 |
try:
|
| 436 |
with sync_playwright() as p:
|
| 437 |
-
browser = p.chromium.launch(
|
|
|
|
|
|
|
|
|
|
| 438 |
ctx = browser.new_context(
|
| 439 |
user_agent='Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/131.0.0.0 Safari/537.36',
|
| 440 |
viewport={'width': 1280, 'height': 720},
|
|
|
|
| 434 |
|
| 435 |
try:
|
| 436 |
with sync_playwright() as p:
|
| 437 |
+
browser = p.chromium.launch(
|
| 438 |
+
headless=True,
|
| 439 |
+
args=['--no-sandbox', '--disable-dev-shm-usage', '--disable-gpu', '--single-process']
|
| 440 |
+
)
|
| 441 |
ctx = browser.new_context(
|
| 442 |
user_agent='Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/131.0.0.0 Safari/537.36',
|
| 443 |
viewport={'width': 1280, 'height': 720},
|