简体   繁体   中英

Microsoft.Bot.Schema.ErrorResponseException: Operation returned an invalid status code 'BadRequest'

Thanks for taking a look at my questions.

The exception of the application exactly as the title.

It was deployed at the AWS server and was integrating with Skype.

The Microsoft.Bot.Schema.ErrorResponseException did not happen when I'm testing my application on local with bot emulator.

It happens only when on Skype.

Env:

  • Microsoft.Bot.Builder 4.2.2
  • Microsoft.Bot.Builder.AI.Luis 4.2.2
  • Microsoft.Bot.Builder.AI.QnA 4.2.2
  • Microsoft.Bot.Connector 4.2.2
Microsoft.Bot.Schema.ErrorResponseException: Operation returned an invalid status code 'BadRequest'
at Microsoft.Bot.Connector.Conversations.ReplyToActivityWithHttpMessagesAsync(String conversationId, String activityId, Activity activity, Dictionary`2 customHeaders, CancellationToken cancellationToken)
at Microsoft.Bot.Connector.ConversationsExtensions.ReplyToActivityAsync(IConversations operations, String conversationId, String activityId, Activity activity, CancellationToken cancellationToken)
at Microsoft.Bot.Builder.BotFrameworkAdapter.SendActivitiesAsync(ITurnContext turnContext, Activity[] activities, CancellationToken cancellationToken)
at Microsoft.Bot.Builder.TurnContext.<>c__DisplayClass22_0.<<SendActivitiesAsync>g__SendActivitiesThroughAdapter|1>d.MoveNext()
--- End of stack trace from previous location where exception was thrown ---

Did anyone know possible reasons of this bug?

Again, thank you so much for helping me.

Because in the message that I sent, it contains HTML tags. So that may crash the application.

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM