From c85dbb23478bafab577be6961afa904c7ebf6e6f Mon Sep 17 00:00:00 2001 From: Soulter <905617992@qq.com> Date: Tue, 10 Jun 2025 22:26:11 +0800 Subject: [PATCH] =?UTF-8?q?fix:=20=E4=BF=AE=E5=A4=8D=E6=9F=90=E4=BA=9B?= =?UTF-8?q?=E6=83=85=E5=86=B5=E4=B8=8B=EF=BC=8C=E4=BC=9A=E8=AF=9D=E6=8E=A7?= =?UTF-8?q?=E5=88=B6=E6=97=A0=E6=95=88=E7=9A=84=E9=97=AE=E9=A2=98?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../platform/sources/aiocqhttp/aiocqhttp_platform_adapter.py | 3 +++ 1 file changed, 3 insertions(+) diff --git a/astrbot/core/platform/sources/aiocqhttp/aiocqhttp_platform_adapter.py b/astrbot/core/platform/sources/aiocqhttp/aiocqhttp_platform_adapter.py index 853ec2288..df8a00ae1 100644 --- a/astrbot/core/platform/sources/aiocqhttp/aiocqhttp_platform_adapter.py +++ b/astrbot/core/platform/sources/aiocqhttp/aiocqhttp_platform_adapter.py @@ -221,6 +221,9 @@ class AiocqhttpAdapter(Platform): a = None if t == "text": current_text = "".join(m["data"]["text"] for m in m_group).strip() + if not current_text: + # 如果文本段为空,则跳过 + continue message_str += current_text a = ComponentTypes[t](text=current_text) # noqa: F405 abm.message.append(a)