We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
copy-pasted from teams-ai repo:
I'm using the JS SDK's StreamingResponse object to stream content to Teams. Here's a minimal repro to get streaming working using StreamingResponse:
StreamingResponse
app.activity(ActivityTypes.Message, async (context: TurnContext, _: ApplicationTurnState) => { const streamer = new StreamingResponse(context); streamer.setGeneratedByAILabel(true); streamer.setFeedbackLoop(true); streamer.setFeedbackLoopType('default'); streamer.queueInformativeUpdate("Processing..."); await sleep(1000); streamer.queueInformativeUpdate("Processing... 2"); await sleep(1000); streamer.queueInformativeUpdate("Processing... 3"); streamer.queueTextChunk("Hello"); await sleep(500); streamer.queueTextChunk("Hello World"); await sleep(100); await streamer.endStream(); });
And in Teams a "Stop" button pops up will streaming is in progress like this:
When I click stop then I get this error in the console log:
RestError: Content stream was cancelled by user. { "name": "RestError", "code": "ContentStreamNotAllowed", "statusCode": 403, "request": { "streamResponseStatusCodes": {}, "url": "<REDACTED>", "method": "POST", "headers": { "statusCode": 403, "request": { "streamResponseStatusCodes": {}, "url": "<REDACTED>", "method": "POST", "headers": { "streamResponseStatusCodes": {}, "url": "<REDACTED>", "method": "POST", "headers": { "method": "POST", "headers": { "_headersMap": { "content-type": "application/json; charset=utf-8", "content-type": "application/json; charset=utf-8", "x-ms-conversation-id": "REDACTED", "accept": "*/*", "user-agent": "Microsoft-BotFramework/3.1 botframework-connector/4.23.2 core-http/3.0.5 Node/v20.0.0 OS/(x64-Windows_NT-10.0.26100) teamsai-js/1.7.3", "authorization": "REDACTED" } }, "withCredentials": false, "timeout": 0, "requestId": "ebe240b0-ca1c-4db7-b4ca-03c91deb75db" }, "details": { "error": { "code": "ContentStreamNotAllowed", "message": "Content stream was cancelled by user." } }, "message": "Content stream was cancelled by user." }
Not sure what the solution is but there should be a way to gracefull handle this scenario in the StreamingResponse class itself.
No response
The text was updated successfully, but these errors were encountered:
No branches or pull requests
copy-pasted from teams-ai repo:
Scenario
I'm using the JS SDK's
StreamingResponse
object to stream content to Teams. Here's a minimal repro to get streaming working usingStreamingResponse
:And in Teams a "Stop" button pops up will streaming is in progress like this:
When I click stop then I get this error in the console log:
Solution
Not sure what the solution is but there should be a way to gracefull handle this scenario in the
StreamingResponse
class itself.Additional Context
No response
The text was updated successfully, but these errors were encountered: