From 6b73b19e54d7e18c3edbb2206e458749c851d582 Mon Sep 17 00:00:00 2001 From: i0cLiceao Date: Sun, 14 Dec 2025 18:23:29 +0800 Subject: [PATCH] fix: support using GitHub Raw content as plugin source (#3975) * Update plugin.py * Update plugin.py * Update plugin.py * Update plugin.py --- astrbot/dashboard/routes/plugin.py | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/astrbot/dashboard/routes/plugin.py b/astrbot/dashboard/routes/plugin.py index c249b07b7..fd808c6c9 100644 --- a/astrbot/dashboard/routes/plugin.py +++ b/astrbot/dashboard/routes/plugin.py @@ -124,7 +124,11 @@ class PluginRoute(Route): session.get(url) as response, ): if response.status == 200: - remote_data = await response.json() + try: + remote_data = await response.json() + except aiohttp.ContentTypeError: + remote_text = await response.text() + remote_data = json.loads(remote_text) # 检查远程数据是否为空 if not remote_data or (