Merge branch 'main' into fix-docs-favicon

This commit is contained in:
Alexander Yue
2025-07-05 20:59:41 -07:00
committed by GitHub
2 changed files with 6 additions and 4 deletions

View File

@@ -1 +0,0 @@
../browser/multiple_agents_same_browser.py

View File

@@ -184,9 +184,12 @@ class TestHeadlessScreenshots:
browser_sessions.append(session)
try:
# Start all sessions in parallel
print('Starting 10 browser sessions in parallel...')
await asyncio.gather(*[session.start() for session in browser_sessions])
# Start all sessions sequentially to avoid playwright_global_object semaphore contention
# The playwright global object semaphore only allows 1 concurrent initialization
print('Starting 10 browser sessions sequentially...')
for i, session in enumerate(browser_sessions):
print(f'Starting session {i + 1}/10...')
await session.start()
# Navigate all sessions to the long page in parallel
print('Navigating all sessions to the long test page...')