from __future__ import annotations from loguru import logger from playwright.async_api import BrowserContext as ASyncContext, async_playwright, Page from hcaptcha_challenger import ModelHub, install from hcaptcha_challenger.agents import AgentT, Malenia async def route_continuation(route, request, host, sitekey): # 检查请求的URL,只拦截特定网站的请求 if request.url == f"https://{host}/": print("start to solve") # 修改DNS解析结果 await route.fulfill(status=200, body="""