Skip to content

Commit 976f04f

Browse files
authored
fix: ignore exceptions from updateInterceptorPatterns (microsoft#2317)
1 parent 51bab39 commit 976f04f

File tree

1 file changed

+8
-1
lines changed

1 file changed

+8
-1
lines changed

playwright/_impl/_page.py

Lines changed: 8 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -262,9 +262,16 @@ async def _on_route(self, route: Route) -> None:
262262
handled = await route_handler.handle(route)
263263
finally:
264264
if len(self._routes) == 0:
265+
266+
async def _update_interceptor_patterns_ignore_exceptions() -> None:
267+
try:
268+
await self._update_interception_patterns()
269+
except Error:
270+
pass
271+
265272
asyncio.create_task(
266273
self._connection.wrap_api_call(
267-
lambda: self._update_interception_patterns(), True
274+
_update_interceptor_patterns_ignore_exceptions, True
268275
)
269276
)
270277
if handled:

0 commit comments

Comments
 (0)
pFad - Phonifier reborn

Pfad - The Proxy pFad of © 2024 Garber Painting. All rights reserved.

Note: This service is not intended for secure transactions such as banking, social media, email, or purchasing. Use at your own risk. We assume no liability whatsoever for broken pages.


Alternative Proxies:

Alternative Proxy

pFad Proxy

pFad v3 Proxy

pFad v4 Proxy