-2

I am using bot framework SDK in Python for Teams channel .

Bot showing "Unable to reach app. Please try again" in adaptive card even my whole process is completed successfully and I got back the responses properly.

error

I also go through https://learn.microsoft.com/en-us/azure/bot-service/bot-builder-howto-long-operations-guidance?view=azure-bot-service-4.0 this but not proper solution in python .

i want solution like .. can I disable the this 10 or 15 second timeout on action button ? OR Is there any other way to increase this 15 sec timeout time ? OR Is there any way action button wait for response on behalf of sending error message ?

sagar
  • 1
  • 2
  • There is a 10 or 15 second timeout that can occur, and if it does then I think that would cause what you're seeing. – Prasad-MSFT Jul 05 '23 at 07:45
  • Accepting / upvoting an answer serves the greater Stack Overflow community and anyone with a similar question. If you feel my answer was sufficient, please "accept" and upvote it. If not, let me know how else I can help! – Steven Kanberg Jul 05 '23 at 20:01

1 Answers1

0

There is no way to disable or otherwise alter the service timeout. That is a function of the Botframework (aka Azure Bot Service) Connector which manages the traffic between the various channels/clients and any bots. In order to avoid service timeout errors, you must have your bot respond within this time frame.

That being said, if you have a "long running operation", the answer is to use a proactive message (doc ref here) which is mentioned in the link you provided. You can also find a working Python sample in the BotFramework-Samples repo located here.

In short, if you know pressing the adaptive card button is going to result in a long running operation, then simply have the bot return a generic response, like "One moment while I retrieve that for you". Meanwhile, the long running process will be working and, once the data is available, you use a proactive message to send the data to the user.

Steven Kanberg
  • 6,078
  • 2
  • 16
  • 35