简体   繁体   中英

Sorry, my bot code is having an issue… But it does not

I have developed a bot with the Microsoft Bot Framework (Builder v3.12.2.4, which is the latest version at this moment). I actually updated all libraries to the latest version, having AdaptiveCards as well, latest beta10.

So, I built the bot, deployed it, everything working great. But all of the sudden, all platforms give the response 'sorry, my bot code is having an issue'. So, at each input, the feedback is given (like hello, a card,...) but also this message.

I checked for double context.Wait() calls, which there are not. I enabled Informational logging and put all kinds of logging, giving below results (no error to be seen in here, as my catch statements would log a row)

2017-12-04T16:45:40  PID[4812] Information Sentiment recognition ON: True
2017-12-04T16:45:41  PID[4812] Information Forwarded message to Luis Dialog: Hallo
2017-12-04T16:45:41  PID[4812] Information Detect Chat intent in Luis Dialog

What I do see, but that was already the case before is:

2017-12-04T16:45:46  PID[4812] Warning     The Bot State API is being deprecated.  
Please refer to https://aka.ms/yr235k for details on how to replace with your own storage.

However, this seems to be something internal on the bot framework... The Bot service says 'I'm fine, no issues found'. So I am running out of ideas.

Anyone encountered this and has a clue. BTW: I have setup adaptive cards for 1 platform (telegram) and using built in herocard on another (skype, web chat) and all are giving this behavior

Additional information. I forgot to put 1 exception logging, being in the API Controller method itself. This one says: Operation returned an invalid status code 'Conflict' However, I have no idea what it means. The default REST API explanations, found via https://docs.microsoft.com/en-us/rest/api/storageservices/common-rest-api-error-codes don't seem to make sense

The error message:

The Bot State API is being deprecated

Means that your chatbot needs to use your own storage for managing state. The URL in the message goes to the Manage custom state data with Azure Cosmos DB for .NET page, which explains why.

Last July, the Bot Framework team blogged about this: Saving State data with BotBuilder-Azure in .NET . If you read a couple of the other blog posts after that, you'll learn how to use other data stores, like SQL Server, for state management.

Really, you want to use your own state management because the amount of storage they provide is very small, improved performance, reduced latency, and greater control over state.

Setting up state should be a normal task for all of your chatbots.

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