fix(qqbot): 补齐 connect() is_reconnect 参数签名 / fix QQAdapter.connect() missing is_reconnect param - #61309
Closed
WenhuaXia wants to merge 1 commit into
Closed
Conversation
…missing is_reconnect param commit 43b8ba4 added is_reconnect kwarg to _connect_adapter_with_timeout() and forwarded it to adapter.connect(). BasePlatformAdapter.connect() already accepts it, and every other platform adapter (telegram, feishu, weixin, etc.) implemented the override — except QQAdapter which was missed. This caused QQBot to fail on startup with: TypeError: QQAdapter.connect() got an unexpected keyword argument 'is_reconnect' Fix: add is_reconnect: bool = False to QQAdapter.connect() signature.
Collaborator
Duplicate of #52966 — byte-identical one-line signature fix adding the keyword-only |
Contributor
|
Thanks for the focused QQBot fix. Automated hermes-sweeper review found that this exact reconnect-contract guarantee is already implemented on current
Closing as implemented on main. |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
摘要 / Summary
commit 43b8ba4 (Jun 25) 在
_connect_adapter_with_timeout()中引入了is_reconnect参数并转发到adapter.connect()。基类BasePlatformAdapter.connect()和所有其他平台 adapter(telegram, feishu, weixin, dingtalk, wecom 等)都已实现该参数签名,但 QQAdapter 遗漏了,导致 QQBot 启动时 TypeError。commit 43b8ba4 (Jun 25) introduced the
is_reconnectkwarg in_connect_adapter_with_timeout()and forwarded it toadapter.connect(). The base classBasePlatformAdapter.connect()and every other platform adapter (telegram, feishu, weixin, dingtalk, wecom, etc.) already implement this signature — but QQAdapter was missed, causing QQBot to crash on startup with a TypeError.错误 / Error
修复 / Fix
一行改动:在
QQAdapter.connect()签名中补齐*, is_reconnect: bool = False。One-line fix: add
*, is_reconnect: bool = FalsetoQQAdapter.connect()signature.影响 / Impact