Skip to content

fix: 使用 GitHub 版 Alconna 兼容新版 QQ 适配器#821

Merged
he0119 merged 2 commits into
mainfrom
fix/alconna-qq
May 26, 2026
Merged

fix: 使用 GitHub 版 Alconna 兼容新版 QQ 适配器#821
he0119 merged 2 commits into
mainfrom
fix/alconna-qq

Conversation

@he0119
Copy link
Copy Markdown
Owner

@he0119 he0119 commented May 26, 2026

变更内容

  • nonebot-plugin-alconna 切换为 GitHub 源,使用上游最新代码以兼容新版 QQ 适配器。
  • 更新 uv.lock,同步 GitHub 源的 Alconna 版本及相关依赖解析结果。
  • 补充 QQ 适配器下 /quota 命令的测试覆盖。
  • 在测试环境中补齐 QQ 适配器用户、超级用户和 uninfo session 缓存。
  • 添加 QQ 群消息事件构造工具,便于后续覆盖 QQ 适配器命令测试。

背景

当前发布版 Alconna 尚未支持最新的 QQ 适配器,导致基于 QQ 适配器的命令测试无法正常工作。本 PR 先直接使用 GitHub 上的 Alconna 最新代码,等待上游正式发布后可再切回 PyPI 版本。

测试覆盖

新增的 QQ 适配器测试用于防止后续再次遇到类似兼容问题,覆盖:

  • 未配置额度 API 时的 /quota 查询提示。
  • 已配置额度 API 时的额度查询结果。
  • 超级用户执行 /quota set
  • 超级用户执行 /quota remove
  • 未配置时执行 /quota remove

验证

  • uv run pytest tests\plugins\llm_quota\test_quota_qq.py -q
  • uv run pytest tests\plugins\llm_quota -q

@github-actions github-actions Bot added the bug Something isn't working label May 26, 2026
@codecov
Copy link
Copy Markdown

codecov Bot commented May 26, 2026

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 86.70%. Comparing base (61b5f25) to head (a078130).
⚠️ Report is 1 commits behind head on main.
✅ All tests successful. No failed tests found.

Additional details and impacted files
@@           Coverage Diff           @@
##             main     #821   +/-   ##
=======================================
  Coverage   86.70%   86.70%           
=======================================
  Files          74       74           
  Lines        2641     2641           
=======================================
  Hits         2290     2290           
  Misses        351      351           

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

@he0119 he0119 changed the title fix: 修复 Alconna 升级后的 QQ 额度测试 fix: 使用 GitHub 版 Alconna 兼容新版 QQ 适配器 May 26, 2026
@he0119 he0119 marked this pull request as ready for review May 26, 2026 16:43
@he0119 he0119 merged commit fc35acf into main May 26, 2026
9 checks passed
@he0119 he0119 deleted the fix/alconna-qq branch May 26, 2026 16:43
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

Successfully merging this pull request may close these issues.

1 participant