Skip to content

fix(msg): 修复图文混排时超级表情截断及接收端解析中断 - #866

Merged
linyuchen merged 7 commits into
LLOneBot:devfrom
VincentZyu233:fix/mixed-super-face-and-parsing-break
Sep 30, 2026
Merged

linyuchen merged 7 commits into
LLOneBot:devfrom
VincentZyu233:fix/mixed-super-face-and-parsing-break

Conversation

@VincentZyu233

@VincentZyu233 VincentZyu233 commented Sep 29, 2026 •

Copy link
Copy Markdown

问题

  1. 发送端:带有 AniStickerType 的超级表情在图文混排时被强制构造为全屏大表情(serviceType: 37),导致 QQ 客户端富文本渲染截断,丢失后续所有内容。
  2. 接收端:messageParsing.ts 在处理 svcType === 37 时误用了 break,导致跳出遍历消息元素的 for 循环,丢弃后续消息段。

修复

  1. 混排消息中(inputElems.length > 1)将超级表情降级为行内小表情形态(serviceType: 33),仅单体唯一表情构造全屏大表情。
  2. 移除 messageParsing 循环内的 break。

复现代码

效果预览

a46601522d8ced1552d53e4c521ac849 > ⬆️ 上面是没有修复这个问题的llbot发出来的,下面是修复了这个问题的llbot发出来的⬇️ 854b61e13e6dbee1c65fc1ba163a0a6f

Sourcery 总结

修复超级贴纸渲染和消息解析问题,确保混合内容消息保留完整内容。

Bug 修复:

  • 解析大表情元素后保留所有消息片段,避免过早终止元素处理。
  • 防止包含超级贴纸的混合内容消息被截断:将其渲染为内联贴纸,同时保留独立贴纸的全屏渲染效果。
Original summary in English

Sourcery 总结

修复超级贴纸渲染和消息解析问题,确保混合内容消息保留完整内容。

错误修复:

  • 解析大贴纸元素后保留所有消息片段,避免过早终止元素处理。
  • 防止包含超级贴纸的混合内容消息被截断:将其以内联方式渲染,同时对独立贴纸保留全屏渲染。
Original summary in English

Sourcery 总结

在正确处理超级贴纸渲染和备用文本的同时,保留完整的混合内容消息。

错误修复:

  • 通过以内联方式渲染包含超级贴纸的混合内容消息,同时保留独立贴纸的全屏渲染,防止消息被截断。
  • 在大表情元素之后继续解析消息元素,并抑制冗余的备用文本片段。
Original summary in English

Sourcery 摘要

修复超级表情的处理逻辑,确保混合消息保持完整,同时让独立动画继续保留全屏显示行为。

Bug 修复:

  • 解析独立超级表情后,保留所有消息元素,仅移除其冗余的回退文本。
  • 防止包含超级表情的文本与图片混合消息因被渲染为行内表情而遭到拒绝或截断。

文档:

  • 记录混合消息发送和回退文本解析的超级表情协议规则。
Original summary in English

Sourcery 摘要

修复超级表情处理逻辑,确保混合消息内容完整,同时保留独立动画表情的全屏渲染效果。

错误修复:

  • 解析独立超级表情元素时,跳过多余的回退文本,而不是终止元素处理,从而保留所有消息片段。
  • 防止包含动画超级表情的文本与媒体混合消息因被拒绝或截断而无法显示:将其渲染为内联表情,同时保留独立表情的全屏显示行为。

文档:

  • 记录独立超级表情消息和混合超级表情消息的协议规则,包括接收过程中回退文本的处理方式。
Original summary in English

Sourcery 总结

在保留独立超大表情全屏渲染效果的同时,完整保留混合消息内容。

错误修复:

  • 通过将包含超大表情的文本与媒体混合消息降级为内联表情渲染,避免此类消息被拒绝或截断。
  • 在独立的大型表情元素之后继续解析消息元素,同时仅移除其冗余的备用文本。

文档:

  • 记录混合消息发送和备用文本解析的超大表情协议规则。
Original summary in English

Sourcery 总结

修复超级表情符号的处理逻辑,确保混合消息保持完整,同时独立的动画表情符号仍可全屏显示。

错误修复:

  • 解析独立的超级表情符号元素后,跳过其冗余的备用文本,以保留所有消息片段。
  • 将包含超级表情符号的文本与媒体混合消息以内联表情符号的形式渲染,避免此类消息被拒绝或截断。

文档:

  • 记录独立和混合超级表情符号消息的协议规则,包括备用文本的处理方式。
Original summary in English

Summary by Sourcery

Fix super emoji handling so mixed messages remain intact while standalone animated emojis retain full-screen rendering.

Bug Fixes:

  • Preserve all message segments after parsing standalone super emoji elements by skipping only their redundant fallback text.
  • Prevent mixed text-and-media messages containing super emojis from being rejected or truncated by rendering them as inline emojis.

Documentation:

  • Document the protocol rules for standalone and mixed super emoji messages, including fallback-text handling.

@sourcery-ai

sourcery-ai Bot commented Sep 29, 2026 •

Copy link
Copy Markdown
Contributor
审查者指南(小型 PR 中折叠显示)

审查者指南

该 PR 通过将混合消息中的动态超级表情编码为行内表情,避免消息被截断,同时保留独立表情的全屏渲染效果;此外,它还修复了接收端的解析逻辑,使服务类型 37 不再停止处理后续元素。

服务类型 37 后继续解析的时序图

sequenceDiagram
    participant P as parseElements
    participant R as ParsedMessage
    P->>P: Decode serviceType 37
    P->>R: Append parsed face element
    P->>P: Continue processing next message element
    P->>R: Append subsequent message segment
Loading

混合消息中超级表情编码的流程图

flowchart TD
    A[Face element] --> B{faceType === 3}
    B -->|yes| C{inputElems.length === 1}
    C -->|yes| D[Encode LargeFaceExtra serviceType 37]
    C -->|no| E[Encode QSmallFaceExtra serviceType 33]
    B -->|no| F{faceType === 2}
    F -->|yes| E
Loading

文件级变更

变更 详情 文件
根据消息是独立消息还是与其他元素混合,选择合适的表情消息编码方式。
  • 保留独立动态表情的大尺寸/全屏表情形式。
  • 将混合消息中的动态表情编码为行内小表情,以保留后续的富文本内容。
  • 保留普通表情现有的小表情编码方式,同时将动态表情纳入行内编码路径。
src/ntqqapi/helper/messageBuilding.ts
解码服务类型 37 的动态表情元素后允许继续解析。
  • 移除服务类型 37 分支中的循环中断语句,以便处理后续消息片段。
src/ntqqapi/helper/messageParsing.ts

可能相关的问题

  • #无法发送和接收QQ表情:PR 将混排超级表情改为行内表情,并移除接收解析中的 break,直接修复发送截断和表情后内容丢失问题。

提示和命令

与 Sourcery 交互

  • 触发新的审查: 在 pull request 中评论 @sourcery-ai review。
  • 继续讨论: 直接回复 Sourcery 的审查评论。
  • 根据审查评论生成 GitHub issue: 回复审查评论,请 Sourcery 根据该评论创建 issue。你也可以使用 @sourcery-ai issue 回复审查评论,以根据该评论创建 issue。
  • 生成 pull request 标题: 在 pull request 标题的任意位置写入 @sourcery-ai,即可随时生成标题。你也可以在 pull request 中评论 @sourcery-ai title,以随时生成或重新生成标题。
  • 生成 pull request 摘要: 在 pull request 正文中任意位置写入 @sourcery-ai summary,即可在指定位置随时生成 PR 摘要。你也可以在 pull request 中评论 @sourcery-ai summary,以随时生成或重新生成摘要。
  • 生成审查者指南: 在 pull request 中评论 @sourcery-ai guide,即可随时生成或重新生成审查者指南。
  • 解决所有 Sourcery 评论: 在 pull request 中评论 @sourcery-ai resolve,即可解决所有 Sourcery 评论。如果你已经处理完所有评论且不想再看到它们,这项功能会很有用。
  • 忽略所有 Sourcery 审查: 在 pull request 中评论 @sourcery-ai dismiss,即可忽略所有现有的 Sourcery 审查。如果你想从新的审查开始,这项功能尤其有用——别忘了评论 @sourcery-ai review 以触发新的审查!

自定义使用体验

访问你的控制面板以:

  • 启用或禁用审查功能,例如 Sourcery 生成的 pull request 摘要、审查者指南等。
  • 更改审查语言。
  • 添加、移除或编辑自定义审查指令。
  • 调整其他审查设置。

获取帮助

Original review guide in English
Reviewer's guide (collapsed on small PRs)

Reviewer's Guide

The PR prevents mixed messages containing animated super stickers from being truncated by encoding them as inline faces, while preserving full-screen rendering for standalone stickers; it also fixes receive-side parsing so service type 37 no longer stops processing subsequent elements.

Sequence diagram for continued parsing after service type 37

sequenceDiagram
    participant P as parseElements
    participant R as ParsedMessage
    P->>P: Decode serviceType 37
    P->>R: Append parsed face element
    P->>P: Continue processing next message element
    P->>R: Append subsequent message segment
Loading

Flow diagram for super sticker encoding in mixed messages

flowchart TD
    A[Face element] --> B{faceType === 3}
    B -->|yes| C{inputElems.length === 1}
    C -->|yes| D[Encode LargeFaceExtra serviceType 37]
    C -->|no| E[Encode QSmallFaceExtra serviceType 33]
    B -->|no| F{faceType === 2}
    F -->|yes| E
Loading

File-Level Changes

Change Details Files
Selects the appropriate face-message encoding based on whether the message is standalone or mixed with other elements.
  • Keeps standalone animated stickers as large/full-screen faces.
  • Encodes animated stickers in mixed messages as inline small faces to preserve subsequent rich-text content.
  • Retains existing small-face encoding for regular faces while including animated stickers in the inline path.
src/ntqqapi/helper/messageBuilding.ts
Allows parsing to continue after decoding service type 37 animated-face elements.
  • Removes the loop-breaking statement from the service type 37 branch so later message segments are processed.
src/ntqqapi/helper/messageParsing.ts

Possibly linked issues

  • #无法发送和接收QQ表情: PR将混排超级表情改为行内表情,并移除接收解析中的break,直接修复发送截断和表情后内容丢失。

Tips and commands

Interacting with Sourcery

  • Trigger a new review: Comment @sourcery-ai review on the pull request.
  • Continue discussions: Reply directly to Sourcery's review comments.
  • Generate a GitHub issue from a review comment: Ask Sourcery to create an
    issue from a review comment by replying to it. You can also reply to a
    review comment with @sourcery-ai issue to create an issue from it.
  • Generate a pull request title: Write @sourcery-ai anywhere in the pull
    request title to generate a title at any time. You can also comment
    @sourcery-ai title on the pull request to (re-)generate the title at any time.
  • Generate a pull request summary: Write @sourcery-ai summary anywhere in
    the pull request body to generate a PR summary at any time exactly where you
    want it. You can also comment @sourcery-ai summary on the pull request to
    (re-)generate the summary at any time.
  • Generate reviewer's guide: Comment @sourcery-ai guide on the pull
    request to (re-)generate the reviewer's guide at any time.
  • Resolve all Sourcery comments: Comment @sourcery-ai resolve on the
    pull request to resolve all Sourcery comments. Useful if you've already
    addressed all the comments and don't want to see them anymore.
  • Dismiss all Sourcery reviews: Comment @sourcery-ai dismiss on the pull
    request to dismiss all existing Sourcery reviews. Especially useful if you
    want to start fresh with a new review - don't forget to comment
    @sourcery-ai review to trigger a new review!

Customizing Your Experience

Access your dashboard to:

  • Enable or disable review features such as the Sourcery-generated pull request
    summary, the reviewer's guide, and others.
  • Change the review language.
  • Add, remove or edit custom review instructions.
  • Adjust other review settings.

Getting Help

@VincentZyu233
VincentZyu233 marked this pull request as ready for review September 29, 2026 17:15

@sourcery-ai sourcery-ai Bot left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

嘿——我发现了 1 个问题

AI 代理提示词
请处理这次代码审查中的评论:

## 个别评论

### 评论 1
<location path="src/ntqqapi/helper/messageBuilding.ts" line_range="83" />
<code_context>
         },
       })
-    } else if (faceElement.faceType === 2) {
+    } else if (faceElement.faceType === 2 || faceElement.faceType === 3) {
       const f = faceElement
       const pbElem = Msg.QSmallFaceExtra.encode({
</code_context>
<issue_to_address>
**issue (broader_impact):** 包含 `faceType === 3` 骰子或剪刀石头布元素的混合消息会被编码为 `serviceType: 33`。该类型使用 `QSmallFaceExtra`,且不携带 `resultId`。因此,接收解析器会将其还原为没有结果的普通 `faceType: 2` 表情,而 OneBot 转换器会生成结果未定义的骰子/剪刀石头布消息段。

**触发条件:** 当 `SendElement.dice()` 或 `SendElement.rps()` 与其他任意消息元素一起包含在消息中时。

**建议修复:** 将降级范围限制为 AniStickerType 超级表情,或将骰子/剪刀石头布保留为 `serviceType: 37`,以便继续编码其 `resultId`。
</issue_to_address>

Sourcery 对开源项目免费——如果您喜欢我们的审查结果,欢迎分享 ✨
Original comment in English

Hey - I've found 1 issue

Prompt for AI Agents
Please address the comments from this code review:

## Individual Comments

### Comment 1
<location path="src/ntqqapi/helper/messageBuilding.ts" line_range="83" />
<code_context>
         },
       })
-    } else if (faceElement.faceType === 2) {
+    } else if (faceElement.faceType === 2 || faceElement.faceType === 3) {
       const f = faceElement
       const pbElem = Msg.QSmallFaceExtra.encode({
</code_context>
<issue_to_address>
**issue (broader_impact):** Mixed messages containing `faceType === 3` dice or rock-paper-scissors elements are encoded as `serviceType: 33`, which uses `QSmallFaceExtra` and does not carry `resultId`. The receive parser therefore reconstructs them as ordinary `faceType: 2` faces with no result, and the OneBot transformer emits dice/RPS segments with an undefined result.

**Triggers:** When `SendElement.dice()` or `SendElement.rps()` is included alongside any other message element.

**Suggested fix:** Restrict the downgrade to AniStickerType super faces, or preserve dice/RPS as `serviceType: 37` so their `resultId` remains encoded.
</issue_to_address>

Sourcery is free for open source - if you like our reviews please consider sharing them ✨

Comment thread src/ntqqapi/helper/messageBuilding.ts
- 发送端:多元素图文混排时将超级表情降级为小表情形态(serviceType: 33),仅在单体唯一表情时构造 serviceType: 37 大表情
- 接收端:移除 messageParsing 遍历 elements 循环中 svcType===37 分支内错误的 break 语句,防止后续消息元素被丢弃

Co-authored-by: gemini-code-assist <200291788+gemini-code-assist@users.noreply.github.com>
@VincentZyu233
VincentZyu233 force-pushed the fix/mixed-super-face-and-parsing-break branch from 3a496c7 to a42c169 Compare September 29, 2026 17:45
@VincentZyu233

Copy link
Copy Markdown
Author

然后似乎会有新的问题,我考虑一下这个 我看看咋搞🤔:

QQ_1790704731561

@VincentZyu233

VincentZyu233 commented Sep 29, 2026 •

Copy link
Copy Markdown
Author

然后似乎会有新的问题

哦哦我大概明白啥意思了。qq的历史包袱: 一些旧版qq or tim 可能不会渲染这种大表情,所以带了一个 降级fallback文本在后面 比如吃糖。 刚刚我用了 我的这个koishi插件https://github.com/VincentZyuApps/koishi-plugin-quote-debug-msg-json-image 打印了一下 get_msg 获取到的结果差异:

451fa6e32555e4b4f15251948e9c5e71 fc54bdcc8ebd751112eeef5e714fa4c0

⬆️ 上面两个图片 左侧的都是去掉了这个break的llbot 拿到的消息,多了一个[吃糖]

1c79f5a2a2f36a96c45fb180411b47a3

@VincentZyu233

VincentZyu233 commented Sep 29, 2026 •

Copy link
Copy Markdown
Author

获取到的结果差异

接着实验:

然后我又试了试这个插件:https://github.com/VincentZyuApps/koishi-plugin-awa-quote-image

bab5ebd46db6b697d8830701b366c275 > ⬆️ 上面的图片是用 没有这个break的llbot获取到的,确实多了一个[吃糖]的降级文本,而下面的是 有break的 直接从dockerhub 拉的 llbot 获取到的 ⬇️ 544ec0295a70c5b3c154c793280dbb5e_720

- 替换原有的 break 语句为针对 fallback 文本的跳过逻辑(skipIndex)
- 自动剔除紧随其后的 [表情描述] 或 [动画表情] 等降级文本,同时确保后续正常消息内容不被截断

Co-authored-by: gemini-code-assist <200291788+gemini-code-assist@users.noreply.github.com>
@VincentZyu233

VincentZyu233 commented Sep 29, 2026 •

Copy link
Copy Markdown
Author

为什么 NapCat 没有遇到这些问题?(兼谈与 Hook 框架的架构差异)

在研究对齐 NapCat(以 NapNeko/NapCatQQ@0b4cfe6 (2026-09-23))时,可以清楚看到 Hook 框架与纯协议框架在处理超级表情上的架构差异:

1. 发送端(混排大表情截断)

2. 接收端(降级文本与 break 隐患)

VincentZyu233 and others added 3 commits September 30, 2026 02:43
- 补充对腾讯服务端在 serviceType: 37 大表情后附带 fallback 纯文本段的机制说明
- 记录实测确认的典型案例(/吃糖 附带 [吃糖],/菜汪 附带 [菜汪] 等)

Co-authored-by: gemini-code-assist <200291788+gemini-code-assist@users.noreply.github.com>
- 注释说明腾讯 QQ 服务端禁止在混排中携带 serviceType: 37(会触发 retcode 1200 拦截)
- 阐明多元素混排时必须降级为 serviceType: 33 的官方客户端行为依据

Co-authored-by: gemini-code-assist <200291788+gemini-code-assist@users.noreply.github.com>
- 新增 docs/super-face-protocol.md 总结 serviceType 33 与 37 协议陷阱与防呆规则
- 在 CLAUDE.md 文档索引表中补充对应条目

Co-authored-by: gemini-code-assist <200291788+gemini-code-assist@users.noreply.github.com>
@VincentZyu233
VincentZyu233 force-pushed the fix/mixed-super-face-and-parsing-break branch from 01d7a85 to 34869a3 Compare September 29, 2026 18:51
@VincentZyu233

Copy link
Copy Markdown
Author

ok 我已经测试过,我本地的llbot 运行符合预期,works on my machine:

图片

本地的经过了这几个commit修改的llbot 用我上面提到的几个koishi插件插件测试以后 观察到的现象:

  1. bot对于 https://github.com/VincentZyuApps/koishi-plugin-auto-emoji-onebot-vincentzyu 这个插件的 **取表情**指令的回复 (实际上关键是 对于这种性质的消息:bot自身发送的,并且至少存在一个faceElement, 并且这个face 带有 serviceType: 37 这种属性, 比如 [吃糖] )不会被截断:

示意效果图(这个吃糖黄豆后面的内容依旧出来了):
QQ_1790708978798

  1. 某一条消息(不一定是bot本身发送的) 被 https://github.com/VincentZyuApps/koishi-plugin-awa-quote-image 这个插件的**aqt**指令解析 渲染成图片中 在去掉了break以后 也不会带有 [吃糖] 这种降级文案

示意效果图(后面没有[吃糖] 这种降级文本了):
图片

  1. 其实是同理2, 用https://github.com/VincentZyuApps/koishi-plugin-quote-debug-msg-json-image 这个插件的 dump-json 指令渲染的图片中也不会含有[吃糖]这种降级文本

示意效果图(作图中 红框示意的这种 [吃糖] 不会再出现了捏)
a23db7bfc24e1089bdc73a7839d661e8

- 明确 LargeFaceExtra 单体发送约束:仅在消息段长度为 1 时构造 serviceType: 37 大表情
- 阐明混排降级分支原理:具备大表情潜质(faceType: 3)的元素在混排时自动委屈降级为 serviceType: 33 小表情形态,避免腾讯服务端报错与客户端截断

Co-authored-by: gemini-code-assist <200291788+gemini-code-assist@users.noreply.github.com>
@VincentZyu233

VincentZyu233 commented Sep 29, 2026 •

Copy link
Copy Markdown
Author

ok啊,我似乎理解更多东西了, 如果我没理解错的话:

在这个commit里面新增了注释, 有关为什么 分别对于两个parse消息的分支情况的判断 增加了 一个and 和 一个or:

9fba353

    } else if (faceElement.faceType === 3 && this.inputElems.length === 1) {                                                                                                                                                                                                                                                                                                                        
      // 腾讯协议约束:超级大表情 LargeFaceExtra(dice / rps / 超级表情等)必须作为单体消息独立发送(消息段数组长度为 1),                                                                                                                                                                                                                                                                         
      // 此时才视为合法的大表情调用,构造 serviceType: 37;若在图文混排等情况(消息段数组的长度 > 1)中强传 37,腾讯服务端会拒收并报错 retcode: 1200。                                                                                                                                                                                                                                                              
      const f = faceElement                                                                                                                                                                                                                                                                                                                                                                         
      const pbElem = Msg.LargeFaceExtra.encode({ ... })                                                                                                                                                                                                                                                                                                                                             
      this.outputElems.push({                                                                                                                                                                                                                                                                                                                                                                       
        commonElem: {                                                                                                                                                                                                                                                                                                                                                                               
          serviceType: 37,                                                                                                                                                                                                                                                                                                                                                                          
          pbElem,                                                                                                                                                                                                                                                                                                                                                                                   
          businessType: f.stickerType ?? 1,                                                                                                                                                                                                                                                                                                                                                         
        },                                                                                                                                                                                                                                                                                                                                                                                          
      })                                                                                                                                                                                                                                                                                                                                                                                            
    } else if (faceElement.faceType === 2 || faceElement.faceType === 3) {                                                                                                                                                                                                                                                                                                                          
      // 1. faceType === 2: 原生小黄豆扩展表情。                                                                                                                                                                                                                                                                                                                                                    
      // 2. faceType === 3: 虽然具有成为大表情的潜质,但由于与其他文字/图片等消息段混排(未通过上方 length === 1 的独立发送检验),                                                                                                                                                                                                                                                                         
      //    因此对齐官方 QQ 客户端行为,委屈其降级为小表情形态(serviceType: 33 / QSmallFaceExtra)打包进消息段数组,确保混排消息完整送达且不截断。                                                                                                                                                                                                                                                 
      const f = faceElement

- 完善图文混排描述:细化为“图文混排等情况(消息段数组的长度 > 1)”
- 明确混排对象范围:补充“与其他文字/图片等消息段混排”

Co-authored-by: gemini-code-assist <200291788+gemini-code-assist@users.noreply.github.com>
@VincentZyu233

Copy link
Copy Markdown
Author

然后似乎会有新的问题,我考虑一下这个 我看看咋搞🤔:
QQ_1790704731561

然后就是有关于 剔除 所谓 commonElem(serviceType=37) = LargeFaceExtra(dice / rps / 超级表情) 这种大表情的 降级文本的 问题, 在这个commit里面,这样做的:

6296b9e

        // 剔除紧随其后的降级文本段(腾讯服务端为兼容老客户端,在下发 serviceType: 37 大表情时会附带 fallback 纯文本段)
        // 实测典型案例:/吃糖 会附带 "[吃糖]",/菜汪 会附带 "[菜汪]",骰子附带 "[骰子]" 等
        // 采用 skipIndex 精准跳过此冗余段,避免直接 break 导致后续正常消息内容被截断
        const nextElem = elems[index + 1]
        if (nextElem?.text?.str) {
          const nextStr = nextElem.text.str
          const faceName = face?.QDes ? face.QDes.replace(/^\//, '') : ''
          const isFallbackText =
            nextStr === '[动画表情]' ||
            (faceName && (nextStr === `[${faceName}]` || nextStr === face.QDes)) ||
            (faceIndex === 358 && nextStr === '[骰子]') ||
            (faceIndex === 359 && (nextStr === '[包剪锤]' || nextStr === '[剪刀石头布]'))
          if (isFallbackText) {
            skipIndex = index + 1
          }
        }

@VincentZyu233

Copy link
Copy Markdown
Author

@VincentZyu233

Copy link
Copy Markdown
Author

ok 我已经测试过,我本地的llbot 运行符合预期,works on my machine:

当然我暂时还没想到 or 测到其他的边界情况 (本pr 可能会引发的更多新问题捏) 所以请review, thanks。

(¦3[▓▓] 晚安 , 心脏有点不好喵

@idranme
idranme changed the base branch from main to dev September 30, 2026 02:37
@linyuchen
linyuchen merged commit f21ca6a into LLOneBot:dev Sep 30, 2026
1 check passed
@VincentZyu233

VincentZyu233 commented Sep 30, 2026 •

Copy link
Copy Markdown
Author

然后就是有关于 剔除

好像直接break也行喵,刚刚和予云叶又聊了一下喵
QQ_1790751811921
图片
QQ_1790750880437

对的对的 予云叶已经新增了新的commit 改回了简洁的break喵

a6df7ab

图片

对的 这么多行剔除可能确实有点过度设计喵,直接break应该也够用了喵 🤔

@VincentZyu233

Copy link
Copy Markdown
Author

好像直接break也行喵

我的思考是这样的,如果llbot遇到了一个serviceType37的 大表情消息段,那么这个一定是单独的一个超大表情,

这个结论建立在这个假设之上: 腾讯既然能把这种消息广播出来,那么腾讯服务端肯定校验过了 这个是一个合法的 单独超大表情消息。

而我觉得这个假设成立的概率很大喵。

@VincentZyu233

Copy link
Copy Markdown
Author

予云叶已经新增了新的commit 改回了简洁的break喵

我刚刚本地也测试了这样的写法,即parse中直接简洁的break,build中新增的一个and 一个or 保持不变

测试结果:
df1b52c011c9b6d81490258b9e784e2d
QQ_1790751314964

可以看到 parse和build的结果都符合预期喵!云叶姐姐说得对喵!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants