Skip to content

Commit 292f17a

Browse files
committed
[Fix] Remove maxRedirects in InitScript Fetching
1 parent 6fb6d5f commit 292f17a

File tree

1 file changed

+6
-2
lines changed

1 file changed

+6
-2
lines changed

patch_python_package.py

Lines changed: 6 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -280,7 +280,9 @@ async def install_inject_route(self) -> None:
280280
async def route_handler(route: Route) -> None:
281281
if route.request.resource_type == "document" and route.request.url.startswith("http"):
282282
try:
283-
response = await route.fetch(maxRedirects=0)
283+
response = await route.fetch(
284+
# maxRedirects=0
285+
)
284286
await route.fulfill(response=response)
285287
except:
286288
await route.continue_()
@@ -334,7 +336,9 @@ async def install_inject_route(self) -> None:
334336
async def route_handler(route: Route) -> None:
335337
if route.request.resource_type == "document" and route.request.url.startswith("http"):
336338
try:
337-
response = await route.fetch(maxRedirects=0)
339+
response = await route.fetch(
340+
# maxRedirects=0
341+
)
338342
await route.fulfill(response=response)
339343
except Exception:
340344
await route.continue_()

0 commit comments

Comments
 (0)