Skip to content
New issue

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

fix: correct QnAMaker response types and expose error from server #3279

Merged
merged 5 commits into from
Feb 8, 2021

Conversation

chon219
Copy link
Member

@chon219 chon219 commented Feb 7, 2021

Fixes #2317

Description

This PR exposed error message from QnAMaker server to allow users locating and fixing errors.
Response type of HttpRequestUtils of QnAMaker is not correctly defined, it should be QnAMakerResults (while calling generate api) or undefined (while calling train api). Check out https://docs.microsoft.com/en-us/rest/api/cognitiveservices/qnamaker4.0/runtime/generateanswer#response . This PR will fix this.

Specific Changes

  • Exposed error from QnAMaker server side
  • Corrected return type to QnAMakerResults

Testing

@chon219 chon219 added the Area: AI-QnAMaker The issue is related to QnA Maker label Feb 7, 2021
@chon219 chon219 added this to the R12 milestone Feb 7, 2021
@chon219 chon219 requested review from a team as code owners February 7, 2021 08:42
@coveralls
Copy link

coveralls commented Feb 7, 2021

Pull Request Test Coverage Report for Build 546784800

  • 0 of 0 changed or added relevant lines in 0 files are covered.
  • 3 unchanged lines in 2 files lost coverage.
  • Overall coverage decreased (-0.002%) to 84.872%

Files with Coverage Reduction New Missed Lines %
libraries/botbuilder-ai/src/qnamaker-utils/generateAnswerUtils.ts 1 86.49%
libraries/adaptive-expressions/src/triggerTrees/trigger.ts 2 61.92%
Totals Coverage Status
Change from base Build 546673406: -0.002%
Covered Lines: 18282
Relevant Lines: 20559

💛 - Coveralls

Copy link
Contributor

@joshgummersall joshgummersall left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Two quick suggestions.

@chon219 chon219 merged commit 93a5cb4 into main Feb 8, 2021
@chon219 chon219 deleted the zim/qnamaker-error-handling branch February 8, 2021 04:05
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Area: AI-QnAMaker The issue is related to QnA Maker
Projects
None yet
Development

Successfully merging this pull request may close these issues.

[Adaptive] QnAMakerRecognizer should not error on missing property configuration.
3 participants