Closed davidimmanuel007 closed 2 years ago
Hi @davidimmanuel007, I'm investigating this one.
Hi @davidimmanuel007,
I see you are using the older bot framework SDK version 3.1.
Do you face the same problem if using the latest Bot Framework SDK 4.17.1? Or is this issue specific to SDK v3?
Thanks.
closing due to inactivity. @davidimmanuel007 please re-open if needed.
Github issues for C# /JS / Java/ Python should be used for bugs and feature requests. Use Stack Overflow for general "how-to" questions.
Sample information
Describe the bug
I'm integrating Livepersonproxybot into my existing bot framework solution as I want to escalate to human agent in some scenario, The sample (LivePersonProxyBot) works fine & the integrated solution of mine is also works fine except this exception **The bot encounted an error 'Cannot access a disposed object.
Object name: ‘SendActivityAsync , Im able to send and receive the messages from bot to agent & agent to bot , but along with each turn I get the above error. Unable to send the activities agent has accepted/Closed the conversation** to the bot, instead of these events Im getting turn errors as mentioned above.
To Reproduce
Steps to reproduce the behavior:
Expected behavior
Bot should receive the messages from the agent except showing -The bot encounted an error 'Cannot access a disposed object. Object name: ‘SendActivityAsync’.
Screenshots
Img 1. the working sample as expected Img 2. the integrated soln which showing the error
Additional context
here is the error stack trace Microsoft.Bot.Builder.Integration.AspNet.Core.BotFrameworkHttpAdapter: Error: [OnTurnError] unhandled error : Cannot access a disposed object. Object name: 'SendActivityAsync'.
System.ObjectDisposedException: Cannot access a disposed object. Object name: 'SendActivityAsync'.
End of stack trace from previous location where exception was thrown --- at Microsoft.Bot.Builder.BotAdapter.RunPipelineAsync(ITurnContext turnContext, BotCallbackHandler callback, CancellationToken cancellationToken) at LivePersonProxyBot.LoggingMiddleware.OnTurnAsync(ITurnContext turnContext, NextDelegate next, CancellationToken cancellationToken) in E:\handoff\DigitalAssistant Latest \LivePersonConnector\Middleware\LoggingMiddleware.cs:line 46 at LivePersonConnector.HandoffMiddleware.OnTurnAsync(ITurnContext turnContext, NextDelegate next, CancellationToken cancellationToken) in E:\handoff\DigitalAssistant Latest \LivePersonConnector\HandoffMiddleware.cs:line 80