Skip to content

[Bug] Plugin fails to load on Python 3.13+: No module named 'imghdr' #1

Description

@HZJprince

Bug Description

TeamChat 插件在 Python 3.13 环境下无法加载,安装直接报错。

Error Log

ERROR qwenpaw/plugins/loader.py:315 | Failed to load plugin 'team_chat': No module named 'imghdr'
Traceback (most recent call last):
  File "qwenpaw/plugins/loader.py", line 272, in load_plugin
    spec.loader.exec_module(module)
  File "team_chat/main.py", line 16, in <module>
    import imghdr
ModuleNotFoundError: No module named 'imghdr'

根因

main.py 第 16 行 import imghdr

imghdr 模块在 Python 3.11 被标记为 deprecated,在 Python 3.13 中已被移除PEP 594)。

环境

  • Python: 3.13
  • OS: Windows 10 AMD64
  • QwenPaw: 1.1.10
  • Plugin: TeamChat v4.0.8(从 platform.agentscope.io/plugins/team_chat 安装)

影响

所有使用 Python 3.13+ 的用户均无法安装此插件。

Activity

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

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions