-
Notifications
You must be signed in to change notification settings - Fork 4.9k
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
[TA] Improve Actions docs and throw when more than one action type #22333
Conversation
@@ -3,11 +3,15 @@ | |||
## 5.1.0-beta.8 (Unreleased) | |||
### New features | |||
- Added support for service version `3.0`. This can be specified in the `TextAnalyticsClientOptions` object under the `ServiceVersion` enum. By default the SDK targets latest supported service version. | |||
- Added AAD support for the `StartAnalyzeHealthcareEntities` methods. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Forgot to add in previous PR
@@ -2408,39 +2396,43 @@ public virtual async Task<AnalyzeActionsOperation> StartAnalyzeActionsAsync(IEnu | |||
|
|||
private AnalyzeActionsOperation StartAnalyzeActions(MultiLanguageBatchInput batchInput, TextAnalyticsActions actions, AnalyzeActionsOptions options = default, CancellationToken cancellationToken = default) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The diff looks all weird. what I did was:
- Create method
ValidateActions
that throws if more than one action type is set - Aggregated all transforms from actions to tasks into a method called
CreateTasks
that can be used by bothStartAnalyzeActions
andStartAnalyzeActionsAsync
methods
@@ -358,7 +358,6 @@ public void AnalyzeOperationWithErrorTest() | |||
{ | |||
ExtractKeyPhrasesActions = new List<ExtractKeyPhrasesAction>() | |||
{ | |||
new ExtractKeyPhrasesAction(), |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Had to remove dup action type as it is no longer supported. The purpose of the tests still maintains which is to validate that we get an error when setting an invalid version.
It required re-record
AnalyzeActions
functionality