diff --git a/gspanel/data_source.py b/gspanel/data_source.py index 9530ece..4543c42 100644 --- a/gspanel/data_source.py +++ b/gspanel/data_source.py @@ -551,10 +551,10 @@ async def getPanelMsg(uid: str, char: str = "all", refresh: bool = False) -> Dic try: page = await browser.new_page() await page.set_viewport_size({"width": 1000, "height": 1500}) - await page.goto("file://" + str(tmpFile.resolve()), timeout=5000) + await page.goto("file://" + str(tmpFile.resolve()), timeout=50000) card = await page.query_selector("body") assert card is not None - picBytes = await card.screenshot(timeout=5000) + picBytes = await card.screenshot(timeout=50000) bio = io.BytesIO(picBytes) bio.name = "card.png" print(f"图片大小 {len(picBytes)} 字节")