我正在使用 python botbuilder-sdk,当服务器发送任何消息时,它会将以下消息打印到控制台: Your credentials class does not support session injection. Performance will not be at the maximum.
我试过只下载在github上找到的示例,但问题仍然存在。
这是我目前用于发送消息的内容。
credentials = MicrosoftAppCredentials(APP_ID, APP_PASSWORD)
connector = ConnectorClient(credentials, base_url=activity.service_url)
reply = self.buildReply(activity, activity.text)
connector.conversations.send_to_conversation(reply.conversation.id, reply)
未知消息似乎是由该send_to_conversation
函数产生的。
任何有关其出现原因的见解都会有所帮助。谢谢!
Python Bot Builder SDK 使用msrest-for-python
. 您可以看到,如果凭证类不包含 asigned_session
或 arefresh_session
方法,则会显示警告消息。您可以在 Bot Builder 源代码中看到MicrosoftAppCredentials
不包含这两种方法中的任何一种。有了这些信息,您可以在 GitHub 上的 Bot Builder Python 存储库中提出问题:https : //github.com/microsoft/botbuilder-python/issues
本文收集自互联网,转载请注明来源。
如有侵权,请联系[email protected] 删除。
我来说两句