nonebot-plugin-follow-withdraw


Namenonebot-plugin-follow-withdraw JSON
Version 0.2.0 PyPI version JSON
download
home_page
SummaryA plugin for nonebot2 that follows the user's withdraw of a command.
upload_time2023-06-19 14:34:19
maintainer
docs_urlNone
authorCMHopeSunshine
requires_python>=3.8,<4.0
licenseMIT
keywords
VCS
bugtrack_url
requirements No requirements were recorded.
Travis-CI No Travis.
coveralls test coverage No coveralls.
            <div align="center">
  <a href="https://v2.nonebot.dev/store"><img src="https://github.com/A-kirami/nonebot-plugin-template/blob/resources/nbp_logo.png" width="180" height="180" alt="NoneBotPluginLogo"></a>
  <br>
  <p><img src="https://github.com/A-kirami/nonebot-plugin-template/blob/resources/NoneBotPlugin.svg" width="240" alt="NoneBotPluginText"></p>
</div>

<div align="center">

# nonebot-plugin-follow-withdraw

_✨ NoneBot2跟随撤回插件 ✨_

<a href="./LICENSE">
    <img src="https://img.shields.io/github/license/CMHopeSunshine/nonebot-plugin-follow-withdraw.svg" alt="license">
</a>
<a href="https://pypi.python.org/pypi/nonebot-plugin-follow-withdraw">
    <img src="https://img.shields.io/pypi/v/nonebot-plugin-follow-withdraw.svg" alt="pypi">
</a>
<img src="https://img.shields.io/badge/python-3.8+-blue.svg" alt="python">

</div>

## 📖 介绍

当触发命令的消息被撤回时,让Bot跟随撤回命令消息结果。

以内置插件`echo`为例:

- 你:`@bot /echo hello world`
- Bot:`hello world`

如果消息`@bot /echo hello world`被撤回了,那Bot将自动撤回它发出的`hello world`

## 💿 安装

在 nonebot2 项目的根目录下打开命令行, 输入以下指令即可安装

```shell
nb plugin install nonebot-plugin-follow-withdraw
```

## ☀ ️适配

现已支持以下适配器:

| 名称             | 测试 | 说明                         |
| ---------------- | ---- | ---------------------------- |
| OneBot(V11、V12) | ✔️    | -                            |
| QQ Guild         | ✔️    | -                            |
| Discord          | ✔️    | -                            |
| Kaiheila         | ❌    | 暂只支持频道消息,不支持私聊 |

部分适配器不支持消息撤回或无法接收消息撤回事件通知,无法支持。

## 🔧 ️配置

| 配置名                         | 默认值                                                       | 说明                                                         |
| ------------------------------ | ------------------------------------------------------------ | ------------------------------------------------------------ |
| follow_withdraw_all             | True                                                         | 为True时撤回所有(如果有多条)与该消息相关的消息,为False则是只撤回第一条 |
| follow_withdraw_interval        | 0.5                                                          | 多条消息时的撤回间隔(单位秒),以防止一瞬间撤回过多消息导致风控( |
| follow_withdraw_enable_adapters | ["OneBot V11", "OneBot V12", "QQ Guild", "Discord", "Kaiheila"] | 启用的适配器类型列表,默认为所有已支持的适配器,可选值请看默认值 |
| follow_withdraw_bot_blacklist   | []                                                           | 不启用跟随撤回的Bot列表,填写Bot的bot_id                     |
| follow_withdraw_plugin_blacklist | [] | 不启用跟随撤回的插件列表 |

此外,本插件还提供了一个仅超级用户可使用的命令`清除消息记录`,来清除本插件记录的消息ID数据。

            

Raw data

            {
    "_id": null,
    "home_page": "",
    "name": "nonebot-plugin-follow-withdraw",
    "maintainer": "",
    "docs_url": null,
    "requires_python": ">=3.8,<4.0",
    "maintainer_email": "",
    "keywords": "",
    "author": "CMHopeSunshine",
    "author_email": "277073121@qq.com",
    "download_url": "https://files.pythonhosted.org/packages/bf/23/4284c59af592af4c824d35bc702baf33cdfdfd7edf6f30f8340041c4064a/nonebot_plugin_follow_withdraw-0.2.0.tar.gz",
    "platform": null,
    "description": "<div align=\"center\">\n  <a href=\"https://v2.nonebot.dev/store\"><img src=\"https://github.com/A-kirami/nonebot-plugin-template/blob/resources/nbp_logo.png\" width=\"180\" height=\"180\" alt=\"NoneBotPluginLogo\"></a>\n  <br>\n  <p><img src=\"https://github.com/A-kirami/nonebot-plugin-template/blob/resources/NoneBotPlugin.svg\" width=\"240\" alt=\"NoneBotPluginText\"></p>\n</div>\n\n<div align=\"center\">\n\n# nonebot-plugin-follow-withdraw\n\n_\u2728 NoneBot2\u8ddf\u968f\u64a4\u56de\u63d2\u4ef6 \u2728_\n\n<a href=\"./LICENSE\">\n    <img src=\"https://img.shields.io/github/license/CMHopeSunshine/nonebot-plugin-follow-withdraw.svg\" alt=\"license\">\n</a>\n<a href=\"https://pypi.python.org/pypi/nonebot-plugin-follow-withdraw\">\n    <img src=\"https://img.shields.io/pypi/v/nonebot-plugin-follow-withdraw.svg\" alt=\"pypi\">\n</a>\n<img src=\"https://img.shields.io/badge/python-3.8+-blue.svg\" alt=\"python\">\n\n</div>\n\n## \ud83d\udcd6 \u4ecb\u7ecd\n\n\u5f53\u89e6\u53d1\u547d\u4ee4\u7684\u6d88\u606f\u88ab\u64a4\u56de\u65f6\uff0c\u8ba9Bot\u8ddf\u968f\u64a4\u56de\u547d\u4ee4\u6d88\u606f\u7ed3\u679c\u3002\n\n\u4ee5\u5185\u7f6e\u63d2\u4ef6`echo`\u4e3a\u4f8b\uff1a\n\n- \u4f60\uff1a`@bot /echo hello world`\n- Bot\uff1a`hello world`\n\n\u5982\u679c\u6d88\u606f`@bot /echo hello world`\u88ab\u64a4\u56de\u4e86\uff0c\u90a3Bot\u5c06\u81ea\u52a8\u64a4\u56de\u5b83\u53d1\u51fa\u7684`hello world`\n\n## \ud83d\udcbf \u5b89\u88c5\n\n\u5728 nonebot2 \u9879\u76ee\u7684\u6839\u76ee\u5f55\u4e0b\u6253\u5f00\u547d\u4ee4\u884c, \u8f93\u5165\u4ee5\u4e0b\u6307\u4ee4\u5373\u53ef\u5b89\u88c5\n\n```shell\nnb plugin install nonebot-plugin-follow-withdraw\n```\n\n## \u2600 \ufe0f\u9002\u914d\n\n\u73b0\u5df2\u652f\u6301\u4ee5\u4e0b\u9002\u914d\u5668\uff1a\n\n| \u540d\u79f0             | \u6d4b\u8bd5 | \u8bf4\u660e                         |\n| ---------------- | ---- | ---------------------------- |\n| OneBot(V11\u3001V12) | \u2714\ufe0f    | -                            |\n| QQ Guild         | \u2714\ufe0f    | -                            |\n| Discord          | \u2714\ufe0f    | -                            |\n| Kaiheila         | \u274c    | \u6682\u53ea\u652f\u6301\u9891\u9053\u6d88\u606f\uff0c\u4e0d\u652f\u6301\u79c1\u804a |\n\n\u90e8\u5206\u9002\u914d\u5668\u4e0d\u652f\u6301\u6d88\u606f\u64a4\u56de\u6216\u65e0\u6cd5\u63a5\u6536\u6d88\u606f\u64a4\u56de\u4e8b\u4ef6\u901a\u77e5\uff0c\u65e0\u6cd5\u652f\u6301\u3002\n\n## \ud83d\udd27 \ufe0f\u914d\u7f6e\n\n| \u914d\u7f6e\u540d                         | \u9ed8\u8ba4\u503c                                                       | \u8bf4\u660e                                                         |\n| ------------------------------ | ------------------------------------------------------------ | ------------------------------------------------------------ |\n| follow_withdraw_all             | True                                                         | \u4e3aTrue\u65f6\u64a4\u56de\u6240\u6709(\u5982\u679c\u6709\u591a\u6761)\u4e0e\u8be5\u6d88\u606f\u76f8\u5173\u7684\u6d88\u606f\uff0c\u4e3aFalse\u5219\u662f\u53ea\u64a4\u56de\u7b2c\u4e00\u6761 |\n| follow_withdraw_interval        | 0.5                                                          | \u591a\u6761\u6d88\u606f\u65f6\u7684\u64a4\u56de\u95f4\u9694(\u5355\u4f4d\u79d2)\uff0c\u4ee5\u9632\u6b62\u4e00\u77ac\u95f4\u64a4\u56de\u8fc7\u591a\u6d88\u606f\u5bfc\u81f4\u98ce\u63a7( |\n| follow_withdraw_enable_adapters | [\"OneBot V11\", \"OneBot V12\", \"QQ Guild\", \"Discord\", \"Kaiheila\"] | \u542f\u7528\u7684\u9002\u914d\u5668\u7c7b\u578b\u5217\u8868\uff0c\u9ed8\u8ba4\u4e3a\u6240\u6709\u5df2\u652f\u6301\u7684\u9002\u914d\u5668\uff0c\u53ef\u9009\u503c\u8bf7\u770b\u9ed8\u8ba4\u503c |\n| follow_withdraw_bot_blacklist   | []                                                           | \u4e0d\u542f\u7528\u8ddf\u968f\u64a4\u56de\u7684Bot\u5217\u8868\uff0c\u586b\u5199Bot\u7684bot_id                     |\n| follow_withdraw_plugin_blacklist | [] | \u4e0d\u542f\u7528\u8ddf\u968f\u64a4\u56de\u7684\u63d2\u4ef6\u5217\u8868 |\n\n\u6b64\u5916\uff0c\u672c\u63d2\u4ef6\u8fd8\u63d0\u4f9b\u4e86\u4e00\u4e2a\u4ec5\u8d85\u7ea7\u7528\u6237\u53ef\u4f7f\u7528\u7684\u547d\u4ee4`\u6e05\u9664\u6d88\u606f\u8bb0\u5f55`\uff0c\u6765\u6e05\u9664\u672c\u63d2\u4ef6\u8bb0\u5f55\u7684\u6d88\u606fID\u6570\u636e\u3002\n",
    "bugtrack_url": null,
    "license": "MIT",
    "summary": "A plugin for nonebot2 that follows the user's withdraw of a command.",
    "version": "0.2.0",
    "project_urls": null,
    "split_keywords": [],
    "urls": [
        {
            "comment_text": "",
            "digests": {
                "blake2b_256": "907df00fd36d5ec176c22e7c75ff77330ca008bef70651f7536c4279651d7888",
                "md5": "b0c218f4d640e3d633473ea569de927e",
                "sha256": "d63aba308d0fc462e05762841e280292c7a1c3d32e47d61a9371ea02e4d5ddec"
            },
            "downloads": -1,
            "filename": "nonebot_plugin_follow_withdraw-0.2.0-py3-none-any.whl",
            "has_sig": false,
            "md5_digest": "b0c218f4d640e3d633473ea569de927e",
            "packagetype": "bdist_wheel",
            "python_version": "py3",
            "requires_python": ">=3.8,<4.0",
            "size": 11721,
            "upload_time": "2023-06-19T14:34:18",
            "upload_time_iso_8601": "2023-06-19T14:34:18.210942Z",
            "url": "https://files.pythonhosted.org/packages/90/7d/f00fd36d5ec176c22e7c75ff77330ca008bef70651f7536c4279651d7888/nonebot_plugin_follow_withdraw-0.2.0-py3-none-any.whl",
            "yanked": false,
            "yanked_reason": null
        },
        {
            "comment_text": "",
            "digests": {
                "blake2b_256": "bf234284c59af592af4c824d35bc702baf33cdfdfd7edf6f30f8340041c4064a",
                "md5": "4f5cd55b62dc81129bb8cf888bef24b1",
                "sha256": "96d5c0214721bb529bfd0705fd8bb7dd6f77c1983bff2fd800b46e7f7b0d79de"
            },
            "downloads": -1,
            "filename": "nonebot_plugin_follow_withdraw-0.2.0.tar.gz",
            "has_sig": false,
            "md5_digest": "4f5cd55b62dc81129bb8cf888bef24b1",
            "packagetype": "sdist",
            "python_version": "source",
            "requires_python": ">=3.8,<4.0",
            "size": 8469,
            "upload_time": "2023-06-19T14:34:19",
            "upload_time_iso_8601": "2023-06-19T14:34:19.293176Z",
            "url": "https://files.pythonhosted.org/packages/bf/23/4284c59af592af4c824d35bc702baf33cdfdfd7edf6f30f8340041c4064a/nonebot_plugin_follow_withdraw-0.2.0.tar.gz",
            "yanked": false,
            "yanked_reason": null
        }
    ],
    "upload_time": "2023-06-19 14:34:19",
    "github": false,
    "gitlab": false,
    "bitbucket": false,
    "codeberg": false,
    "lcname": "nonebot-plugin-follow-withdraw"
}
        
Elapsed time: 1.48418s