refactor: remove unavailable channels

This commit is contained in:
zhayujie
2026-03-16 11:05:45 +08:00
parent ba915f2cc0
commit c4b5f7fbae
45 changed files with 8 additions and 6173 deletions

View File

@@ -81,7 +81,7 @@
```
- `isgroup`: `Context`是否是群聊消息。
- `msg`: `itchat`中原始的消息对象。
- `msg`: the original message object from the channel.
- `receiver`: 需要回复消息的对象ID。
- `session_id`: 会话ID(一般是发送触发bot消息的用户ID如果在群聊中并且`conf`里设置了`group_chat_in_one_session`那么此处便是群聊ID)

View File

@@ -59,7 +59,7 @@ COMMANDS = {
},
"id": {
"alias": ["id", "用户"],
"desc": "获取用户id", # wechaty和wechatmp的用户id不会变化可用于绑定管理员
"desc": "获取用户id",
},
"reset": {
"alias": ["reset", "重置会话"],
@@ -204,7 +204,7 @@ class Godcmd(Plugin):
COMMANDS["reset"]["alias"].append(custom_command)
self.password = gconf["password"]
self.admin_users = gconf["admin_users"] # 预存的管理员账号这些账号不需要认证。itchat的用户名每次都会变不可用
self.admin_users = gconf["admin_users"]
global_config["admin_users"] = self.admin_users
self.isrunning = True # 机器人是否运行中

View File

@@ -71,7 +71,6 @@ class Keyword(Plugin):
response = requests.get(reply_text)
with open(file_path, "wb") as f:
f.write(response.content)
#channel/wechat/wechat_channel.py和channel/wechat_channel.py中缺少ReplyType.FILE类型。
reply = Reply()
reply.type = ReplyType.FILE
reply.content = file_path

View File

@@ -216,11 +216,6 @@ class Tool(Plugin):
"browser_use_summary": kwargs.get("browser_use_summary", True), # 是否对返回结果使用tool功能
# for url-get tool
"url_get_use_summary": kwargs.get("url_get_use_summary", True), # 是否对返回结果使用tool功能
# for wechat tool
"wechat_hot_reload": kwargs.get("wechat_hot_reload", True), # 是否使用热重载的方式发送wechat
"wechat_cpt_path": kwargs.get("wechat_cpt_path", os.path.join(get_appdata_dir(), "itchat.pkl")), # wechat 配置文件(`itchat.pkl`
"wechat_send_group": kwargs.get("wechat_send_group", False), # 是否向群组发送消息
"wechat_nickname_mapping": kwargs.get("wechat_nickname_mapping", "{}"), # 关于人的代号映射关系。键为代号值为微信名(昵称、备注名均可)
# for wikipedia tool
"wikipedia_top_k_results": kwargs.get("wikipedia_top_k_results", 2), # 只返回前k个搜索结果
# for wolfram-alpha tool