Skip to main content

基于nonebot的报错处理插件,支持图片/文字发送、数据库存储及跨平台

Project description

这里放一张oc饭🤤

NoneBot 错误管理插件

✨ 智能记录并可视化机器人运行时的错误信息 ✨

📝 插件介绍

这是一个基于 NoneBot2 的错误处理插件,提供以下功能:

  • 实时捕获并绘制错误详细信息为图片
  • 支持错误信息的持久化存储与管理
  • 多样化的错误查询与统计功能
  • 支持多平台适配

🎯 功能特点

  • 自动将错误信息转换为图片发送(失败时自动切换为文本模式)
  • 支持错误信息的数据库存储
  • 提供丰富的错误管理命令
  • 基于 nonebot-plugin-userinfo 获取用户信息
  • 使用 nonebot_plugin_alconna 提供优雅的命令交互

💿 安装方式

pip install nonebot-plugin-error-manager

🎮 使用方法

配置详情

  • error_image_quality - 错误图片绘制质量,默认为 30
  • error_image_font - 错误图片字体,默认为 "Source Han Sans CN"

基础命令

  • /错误管理 查看 [页数] - 分页查看错误记录
  • /错误管理 详情 [id] - 查看指定ID的错误详情
  • /错误管理 删除 [id] - 删除指定ID的错误记录
  • /错误管理 统计 - 查看错误统计信息

高级查询

  • /错误管理 查找 <字段名> <值> - 精确查找错误记录
  • /错误管理 搜索 <关键词> - 模糊搜索错误记录
  • /错误管理 清空 <类型> <值> - 批量清理错误记录
    • 类型:all/user/bot/date
    • 值:all/用户ID/机器人ID/日期

别名支持

支持使用 错误err 作为命令别名。

📸 效果展示

示例图片

🙏 鸣谢

📄 开源协议

MIT License

Copyright (c) 2025 huanxin996

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

nonebot_plugin_error_report-0.0.1.tar.gz (10.7 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

nonebot_plugin_error_report-0.0.1-py3-none-any.whl (10.7 kB view details)

Uploaded Python 3

File details

Details for the file nonebot_plugin_error_report-0.0.1.tar.gz.

File metadata

File hashes

Hashes for nonebot_plugin_error_report-0.0.1.tar.gz
Algorithm Hash digest
SHA256 ce7df24b2660b60b53c30d64a42efbe5e871e06a0f680821fa2d0c52875761f0
MD5 d03609e22d76910b5b727f66d4ff86bd
BLAKE2b-256 55b88a32a0bec64ed83e00ba52adde182a241fe6cbd51040cedf5ed79c4e3e15

See more details on using hashes here.

File details

Details for the file nonebot_plugin_error_report-0.0.1-py3-none-any.whl.

File metadata

File hashes

Hashes for nonebot_plugin_error_report-0.0.1-py3-none-any.whl
Algorithm Hash digest
SHA256 d2ce4348696a7eda6fcc47bf2712c09e6e8eac484960728fcdcba5a6f9b17969
MD5 04dbb214fc6e945c1139971e5736fd64
BLAKE2b-256 a1ab75363640a46670d10c49ffd06c268132556a9c38dc30e21af860426a51fb

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page