Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

群里@机器人没有在群里回复,而是私聊窗口回复的 #281

Open
HenryBao91 opened this issue Jul 31, 2024 · 1 comment
Open
Labels
question Further information is requested

Comments

@HenryBao91
Copy link

HenryBao91 commented Jul 31, 2024

问题描述 🤔

我搭建了ChatGLM3-6b和飞书机器人应用,然后建了群,在群里@机器人,机器人都不在群里回复消息,而是都私聊发给用户而不是在群里回复,下面是截图。
iShot_2024-07-31_14 32 44
iShot_2024-07-31_14 32 58

附加信息 📝

看到issue和Q&A里的设置BOT_NAME的问题,但是我检查了,没有错误。一下是我的输出信息

  • 输出日志
2024-07-31 14:51:21,604 INFO Feishu message: {'sender': {'sender_id': {'user_id': 'df87b7e9', 'open_id': 'ou_97704ed2432b27a4746e22e36fc61bff', 'union_id': 'on_ec5a0e6125bbbffc80b9e1a03294d1fd'}, 'sender_type': 'user', 'tenant_key': '1739c14fb825975e'}, 'message': {'__int_to_string_fields__': ['create_time'], 'message_id': 'om_c26e43d2ec2f5816ac53dc6bc51aa01b', 'root_id': None, 'parent_id': None, 'create_time': 1722408680902, 'chat_id': 'oc_6680119a338fe2cdf89cbd291a686b8d', 'chat_type': 'group', 'message_type': 'text', 'content': '{"text":"@_user_1 你多少岁了"}', 'mentions': [{'key': '@_user_1', 'id': {'user_id': '', 'open_id': 'ou_910cd6739dacc37a7a53debaae5d4c0a', 'union_id': 'on_9b0d36cd3043eac52e4d1008e885b051'}, 'name': 'ChatBotter', 'tenant_key': '1739c14fb825975e'}]}}

 11.8.1.6 - - [31/Jul/2024 14:51:24] "POST /webhook/event HTTP/1.1" 200 -
 11.8.1.6 - - [31/Jul/2024 14:51:28] "POST /webhook/event HTTP/1.1" 200 -
 2024-07-31 14:51:40,386 INFO Feishu message: {'sender': {'sender_id': {'user_id': 'df87b7e9', 'open_id': 'ou_97704ed2432b27a4746e22e36fc61bff', 'union_id': 'on_ec5a0e6125bbbffc80b9e1a03294d1fd'}, 'sender_type': 'user', 'tenant_key': '1739c14fb825975e'}, 'message': {'__int_to_string_fields__': ['create_time'], 'message_id': 'om_c26e43d2ec2f5816ac53dc6bc51aa01b', 'root_id': None, 'parent_id': None, 'create_time': 1722408680902, 'chat_id': 'oc_6680119a338fe2cdf89cbd291a686b8d', 'chat_type': 'group', 'message_type': 'text', 'content': '{"text":"@_user_1 你多少岁了"}', 'mentions': [{'key': '@_user_1', 'id': {'user_id': '', 'open_id': 'ou_910cd6739dacc37a7a53debaae5d4c0a', 'union_id': 'on_9b0d36cd3043eac52e4d1008e885b051'}, 'name': 'ChatBotter', 'tenant_key': '1739c14fb825975e'}]}}
 11.8.1.6 - - [31/Jul/2024 14:51:40] "POST /webhook/event HTTP/1.1" 200 -
  • 相关的代码片段或文件
    config.yml 配置如下
    iShot_2024-07-31_15 01 20

环境变量

> echo $BOT_NAME
ChatBotter

飞书后台配置:
iShot_2024-07-31_14 57 44

求助!🙏

@HenryBao91 HenryBao91 added the question Further information is requested label Jul 31, 2024
@HenryBao91
Copy link
Author

iShot_2024-07-31_22 53 14
看了下 handler/message_handler.py 里的逻辑,这里发送消息确实写的是发送给 user ,而不是发到群里

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
question Further information is requested
Projects
None yet
Development

No branches or pull requests

1 participant