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

Update GetValue to throw on error - HOLD #6604

Closed
wants to merge 2 commits into from

Conversation

ceciliaavila
Copy link
Collaborator

#minor

Description

This PR updates the GetValue method in ExpressionProperty to throw when there's an invalid expression.
This was reported as part of an issue in Composer where an invalid expression was causing an error in JS while .NET was letting it pass.
This PR also fixes an issue in the ConfirmInput class where an invalid expression was being ignored.

Specific Changes

  • Updated the GetValue method in ExpressionProperty to throw in case of an error.
  • Updated OnRecognizeInputAsync in ConfirmInput to use the GetChoiceOptionsAsync to retrieve the options from an lg template.

Testing

These images show the related unit tests passing after the changes.
image

@ceciliaavila ceciliaavila added the Automation: No parity PR does not need to be applied to other languages. label Mar 17, 2023
@ceciliaavila ceciliaavila requested a review from a team as a code owner March 17, 2023 19:30
@coveralls
Copy link
Collaborator

Pull Request Test Coverage Report for Build 344543

  • 0 of 0 changed or added relevant lines in 0 files are covered.
  • 17 unchanged lines in 5 files lost coverage.
  • Overall coverage decreased (-0.01%) to 79.092%

Files with Coverage Reduction New Missed Lines %
/libraries/AdaptiveExpressions/BuiltinFunctions/GetNextViableTime.cs 1 93.94%
/libraries/AdaptiveExpressions/BuiltinFunctions/GetPreviousViableTime.cs 1 93.94%
/libraries/Microsoft.Bot.Streaming/Payloads/StreamManager.cs 1 90.0%
/libraries/Microsoft.Bot.Builder.Dialogs.Adaptive/Input/ConfirmInput.cs 5 85.53%
/libraries/AdaptiveExpressions/ExpressionProperties/ExpressionProperty.cs 9 69.49%
Totals Coverage Status
Change from base Build 344537: -0.01%
Covered Lines: 25815
Relevant Lines: 32639

💛 - Coveralls

@tracyboehrer tracyboehrer changed the title Update GetValue to throw on error Update GetValue to throw on error - HOLD Nov 15, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Automation: No parity PR does not need to be applied to other languages.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants