TurnContext objects get disposed in Microsoft bot framework session timeout function
Tanzeel Ali
1
Reputation point
I'm working on a scenario where the user is warned after 1 minute of inactivity and after another, 1-minute chat will auto close.
Callback is successfully invoked after 1 minute but when I'm using TurnContext to send a message to user then it shows an exception that "cannot access a disposed object".
The Locale in TurnContext is shown null and Microsoft.Bot.Connector.IConnectorClient is also null in TurnContext.TurnState
Can we prevent the object from getting disposed or if there is any other solution so please help me.
Thank you!
Azure AI Bot Service
Azure AI Bot Service
An Azure service that provides an integrated environment for bot development.
941 questions
Developer technologies | ASP.NET | ASP.NET Core
4,816 questions
Sign in to answer