fix: disable SSL verification for proxy/VPN environments

Add verify=False to all httpx.AsyncClient calls across bilibili,
weibo, zhihu clients and crawler_util. Fixes SSL certificate
validation errors when running behind a corporate proxy or VPN.

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
This commit is contained in:
Wei Liu
2026-03-18 12:21:27 +13:00
parent 6742cd598b
commit eb45a6367f
4 changed files with 7 additions and 7 deletions

View File

@@ -47,7 +47,7 @@ async def find_login_qrcode(page: Page, selector: str) -> str:
)
login_qrcode_img = str(await elements.get_property("src")) # type: ignore
if "http://" in login_qrcode_img or "https://" in login_qrcode_img:
async with httpx.AsyncClient(follow_redirects=True) as client:
async with httpx.AsyncClient(follow_redirects=True, verify=False) as client:
utils.logger.info(f"[find_login_qrcode] get qrcode by url:{login_qrcode_img}")
resp = await client.get(login_qrcode_img, headers={"User-Agent": get_user_agent()})
if resp.status_code == 200: