botframework-sdk icon indicating copy to clipboard operation
botframework-sdk copied to clipboard

Bot Framework Emulator Crashing When Bot Sends Long String Response

Open XelaMon opened this issue 10 years ago • 1 comments

Hi,

I am writing a bot in Bot Builder where I am trying to send a very long string. I noticed that the REST Framework appears to have a limit in text of 8192 characters, so I am attempting to get around that by sending multiple messages in a single response to user input. However, when I attempt to this, the emulator starts hanging, and I eventually have to force end it from Task Manager. Any idea what's going on?

var message = String.Empty; foreach (var myString in myList) { if ((message.Length + myString.Length + Environment.NewLine.Length) > 8192) { if (message.Length < 8192) { await context.PostAsync(message); } message = String.Empty; } message += String.Concat(myString, Environment.NewLine); }

XelaMon avatar May 19 '16 23:05 XelaMon

I cannot repro this. I think it is fixed

tomlm avatar May 25 '16 16:05 tomlm