Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

报错:OtherClientOnlineEvent 不是 Event 的子类 #27

Closed
keuin opened this issue Sep 12, 2021 · 1 comment
Closed

报错:OtherClientOnlineEvent 不是 Event 的子类 #27

keuin opened this issue Sep 12, 2021 · 1 comment
Labels
bug Something isn't working

Comments

@keuin
Copy link

keuin commented Sep 12, 2021

yiri-mirai版本:0.2.4.2(目前pypi的最新版)

控制台会有不少这样的错误消息:

[ERROR][2021-09-11 22:53:48,945][base_events.py][1738] Task exception was never retrieved
future: <Task finished name='Task-22' coro=<Adapter.emit() done, defined at X:\some\path\lib\site-packages\mirai\adapters\base.py:174> exception=ValueError('`OtherClientOnlineEvent` 不是 `Event` 的子类!')>
Traceback (most recent call last):
  File "X:\some\path\lib\site-packages\mirai\adapters\base.py", line 183, in emit
    return sum(await asyncio.gather(*coros), [])
  File "X:\some\path\lib\site-packages\mirai\bus.py", line 187, in emit
    for m_event in self.event_chain_generator(event):
  File "X:\some\path\lib\site-packages\mirai\models\bus.py", line 23, in event_chain_parents
    event_type = Event.get_subtype(event)
  File "X:\some\path\lib\site-packages\mirai\models\base.py", line 90, in get_subtype
    raise ValueError(f'`{name}` 不是 `{cls.__name__}` 的子类!')
ValueError: `OtherClientOnlineEvent` 不是 `Event` 的子类!

看起来在其他客户端登录了bot的QQ时,会出现这个错误。

@Wybxc Wybxc added the bug Something isn't working label Sep 12, 2021
@Wybxc Wybxc closed this as completed in 1c1b4e1 Sep 12, 2021
@Wybxc
Copy link
Collaborator

Wybxc commented Sep 12, 2021

0.2.4.3 已发布,修复该问题。

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

2 participants