-
Notifications
You must be signed in to change notification settings - Fork 5k
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
Duplicate the BaseResolution in analyze-text and analyze-conversations #21526
Duplicate the BaseResolution in analyze-text and analyze-conversations #21526
Conversation
Hi, @bidisha-c Thanks for your PR. I am workflow bot for review process. Here are some small tips. Any feedback about review process or workflow bot, pls contact swagger and tools team. vscswagger@microsoft.com |
Swagger Validation Report
|
compared swaggers (via Oad v0.10.2)] | new version | base version |
---|---|---|
analyzeconversations.json | 2023-05-01(dc50a14) | 2023-05-01(main) |
analyzetext.json | 2023-05-01(dc50a14) | 2023-05-01(main) |
common.json | 2023-05-01(dc50a14) | 2023-05-01(main) |
analyzeconversations.json | 2022-10-01-preview(dc50a14) | 2022-10-01-preview(main) |
analyzetext.json | 2022-10-01-preview(dc50a14) | 2022-10-01-preview(main) |
common.json | 2022-10-01-preview(dc50a14) | 2022-10-01-preview(main) |
analyzeconversations.json | 2022-05-01(dc50a14) | 2022-05-01(main) |
Only 16 items are listed, please refer to log for more details.
Rule | Message |
---|---|
1006 - RemovedDefinition |
The new version is missing a definition that was found in the old version. Was 'AgeResolution' removed or renamed? New: cognitiveservices/data-plane/Language/common.json#L9:3 Old: cognitiveservices/data-plane/Language/common.json#L9:3 |
1006 - RemovedDefinition |
The new version is missing a definition that was found in the old version. Was 'VolumeResolution' removed or renamed? New: cognitiveservices/data-plane/Language/common.json#L9:3 Old: cognitiveservices/data-plane/Language/common.json#L9:3 |
1006 - RemovedDefinition |
The new version is missing a definition that was found in the old version. Was 'SpeedResolution' removed or renamed? New: cognitiveservices/data-plane/Language/common.json#L9:3 Old: cognitiveservices/data-plane/Language/common.json#L9:3 |
1006 - RemovedDefinition |
The new version is missing a definition that was found in the old version. Was 'AreaResolution' removed or renamed? New: cognitiveservices/data-plane/Language/common.json#L9:3 Old: cognitiveservices/data-plane/Language/common.json#L9:3 |
1006 - RemovedDefinition |
The new version is missing a definition that was found in the old version. Was 'LengthResolution' removed or renamed? New: cognitiveservices/data-plane/Language/common.json#L9:3 Old: cognitiveservices/data-plane/Language/common.json#L9:3 |
1006 - RemovedDefinition |
The new version is missing a definition that was found in the old version. Was 'InformationResolution' removed or renamed? New: cognitiveservices/data-plane/Language/common.json#L9:3 Old: cognitiveservices/data-plane/Language/common.json#L9:3 |
1006 - RemovedDefinition |
The new version is missing a definition that was found in the old version. Was 'TemperatureResolution' removed or renamed? New: cognitiveservices/data-plane/Language/common.json#L9:3 Old: cognitiveservices/data-plane/Language/common.json#L9:3 |
1006 - RemovedDefinition |
The new version is missing a definition that was found in the old version. Was 'WeightResolution' removed or renamed? New: cognitiveservices/data-plane/Language/common.json#L9:3 Old: cognitiveservices/data-plane/Language/common.json#L9:3 |
1006 - RemovedDefinition |
The new version is missing a definition that was found in the old version. Was 'CurrencyResolution' removed or renamed? New: cognitiveservices/data-plane/Language/common.json#L9:3 Old: cognitiveservices/data-plane/Language/common.json#L9:3 |
1006 - RemovedDefinition |
The new version is missing a definition that was found in the old version. Was 'BooleanResolution' removed or renamed? New: cognitiveservices/data-plane/Language/common.json#L9:3 Old: cognitiveservices/data-plane/Language/common.json#L9:3 |
1006 - RemovedDefinition |
The new version is missing a definition that was found in the old version. Was 'DateTimeResolution' removed or renamed? New: cognitiveservices/data-plane/Language/common.json#L9:3 Old: cognitiveservices/data-plane/Language/common.json#L9:3 |
1006 - RemovedDefinition |
The new version is missing a definition that was found in the old version. Was 'NumberResolution' removed or renamed? New: cognitiveservices/data-plane/Language/common.json#L9:3 Old: cognitiveservices/data-plane/Language/common.json#L9:3 |
1006 - RemovedDefinition |
The new version is missing a definition that was found in the old version. Was 'OrdinalResolution' removed or renamed? New: cognitiveservices/data-plane/Language/common.json#L9:3 Old: cognitiveservices/data-plane/Language/common.json#L9:3 |
1006 - RemovedDefinition |
The new version is missing a definition that was found in the old version. Was 'TemporalSpanResolution' removed or renamed? New: cognitiveservices/data-plane/Language/common.json#L9:3 Old: cognitiveservices/data-plane/Language/common.json#L9:3 |
1006 - RemovedDefinition |
The new version is missing a definition that was found in the old version. Was 'NumericRangeResolution' removed or renamed? New: cognitiveservices/data-plane/Language/common.json#L9:3 Old: cognitiveservices/data-plane/Language/common.json#L9:3 |
1006 - RemovedDefinition |
The new version is missing a definition that was found in the old version. Was 'TemporalModifier' removed or renamed? New: cognitiveservices/data-plane/Language/common.json#L9:3 Old: cognitiveservices/data-plane/Language/common.json#L9:3 |
️❌
Breaking Change(Cross-Version): 20 Errors, 45 Warnings failed [Detail]
compared swaggers (via Oad v0.10.2)] | new version | base version |
---|---|---|
analyzeconversations.json | 2023-05-01(dc50a14) | 2022-05-01(main) |
analyzeconversations.json | 2023-05-01(dc50a14) | 2022-10-01-preview(main) |
analyzetext.json | 2023-05-01(dc50a14) | 2022-05-01(main) |
analyzetext.json | 2023-05-01(dc50a14) | 2022-10-01-preview(main) |
common.json | 2023-05-01(dc50a14) | 2022-05-01(main) |
common.json | 2023-05-01(dc50a14) | 2022-10-01-preview(main) |
The following breaking changes are detected by comparison with the latest stable version:
Only 16 items are listed, please refer to log for more details.
Rule | Message |
---|---|
1023 - TypeFormatChanged |
The new version has a different format than the previous one. New: cognitiveservices/data-plane/Language/analyzeconversations.json#L1345:9 Old: Language/stable/2022-05-01/analyzeconversations.json#L1221:9 |
1026 - TypeChanged |
The new version has a different type 'number' than the previous one 'string'. New: cognitiveservices/data-plane/Language/analyzeconversations.json#L1345:9 Old: Language/stable/2022-05-01/analyzeconversations.json#L1221:9 |
1034 - AddedRequiredProperty |
The new version has new required property 'entities' that was not found in the old version. |
1034 - AddedRequiredProperty |
The new version has new required property 'relations' that was not found in the old version. |
1034 - AddedRequiredProperty |
The new version has new required property 'id' that was not found in the old version. |
1034 - AddedRequiredProperty |
The new version has new required property 'warnings' that was not found in the old version. |
1034 - AddedRequiredProperty |
The new version has new required property 'entities, relations, id, warnings' that was not found in the old version. New: cognitiveservices/data-plane/Language/analyzetext.json#L834:11 Old: Language/stable/2022-05-01/analyzetext.json#L779:11 |
1034 - AddedRequiredProperty |
The new version has new required property 'entities' that was not found in the old version. |
1034 - AddedRequiredProperty |
The new version has new required property 'id' that was not found in the old version. |
1034 - AddedRequiredProperty |
The new version has new required property 'warnings' that was not found in the old version. |
1034 - AddedRequiredProperty |
The new version has new required property 'entities, id, warnings' that was not found in the old version. New: cognitiveservices/data-plane/Language/analyzetext.json#L1505:11 Old: Language/stable/2022-05-01/analyzetext.json#L1430:11 |
1034 - AddedRequiredProperty |
The new version has new required property 'entities' that was not found in the old version. |
1034 - AddedRequiredProperty |
The new version has new required property 'id' that was not found in the old version. |
1034 - AddedRequiredProperty |
The new version has new required property 'warnings' that was not found in the old version. |
1034 - AddedRequiredProperty |
The new version has new required property 'entities, id, warnings' that was not found in the old version. New: cognitiveservices/data-plane/Language/analyzetext.json#L1658:11 Old: Language/stable/2022-05-01/analyzetext.json#L1559:11 |
1034 - AddedRequiredProperty |
The new version has new required property 'redactedText' that was not found in the old version. |
The following breaking changes are detected by comparison with the latest preview version:
Only 16 items are listed, please refer to log for more details.
Rule | Message |
---|---|
The new version is missing a definition that was found in the old version. Was 'AgeResolution' removed or renamed? New: cognitiveservices/data-plane/Language/common.json#L9:3 Old: Language/preview/2022-10-01-preview/common.json#L9:3 |
|
The new version is missing a definition that was found in the old version. Was 'VolumeResolution' removed or renamed? New: cognitiveservices/data-plane/Language/common.json#L9:3 Old: Language/preview/2022-10-01-preview/common.json#L9:3 |
|
The new version is missing a definition that was found in the old version. Was 'SpeedResolution' removed or renamed? New: cognitiveservices/data-plane/Language/common.json#L9:3 Old: Language/preview/2022-10-01-preview/common.json#L9:3 |
|
The new version is missing a definition that was found in the old version. Was 'AreaResolution' removed or renamed? New: cognitiveservices/data-plane/Language/common.json#L9:3 Old: Language/preview/2022-10-01-preview/common.json#L9:3 |
|
The new version is missing a definition that was found in the old version. Was 'LengthResolution' removed or renamed? New: cognitiveservices/data-plane/Language/common.json#L9:3 Old: Language/preview/2022-10-01-preview/common.json#L9:3 |
|
The new version is missing a definition that was found in the old version. Was 'InformationResolution' removed or renamed? New: cognitiveservices/data-plane/Language/common.json#L9:3 Old: Language/preview/2022-10-01-preview/common.json#L9:3 |
|
The new version is missing a definition that was found in the old version. Was 'TemperatureResolution' removed or renamed? New: cognitiveservices/data-plane/Language/common.json#L9:3 Old: Language/preview/2022-10-01-preview/common.json#L9:3 |
|
The new version is missing a definition that was found in the old version. Was 'WeightResolution' removed or renamed? New: cognitiveservices/data-plane/Language/common.json#L9:3 Old: Language/preview/2022-10-01-preview/common.json#L9:3 |
|
The new version is missing a definition that was found in the old version. Was 'CurrencyResolution' removed or renamed? New: cognitiveservices/data-plane/Language/common.json#L9:3 Old: Language/preview/2022-10-01-preview/common.json#L9:3 |
|
The new version is missing a definition that was found in the old version. Was 'BooleanResolution' removed or renamed? New: cognitiveservices/data-plane/Language/common.json#L9:3 Old: Language/preview/2022-10-01-preview/common.json#L9:3 |
|
The new version is missing a definition that was found in the old version. Was 'DateTimeResolution' removed or renamed? New: cognitiveservices/data-plane/Language/common.json#L9:3 Old: Language/preview/2022-10-01-preview/common.json#L9:3 |
|
The new version is missing a definition that was found in the old version. Was 'NumberResolution' removed or renamed? New: cognitiveservices/data-plane/Language/common.json#L9:3 Old: Language/preview/2022-10-01-preview/common.json#L9:3 |
|
The new version is missing a definition that was found in the old version. Was 'OrdinalResolution' removed or renamed? New: cognitiveservices/data-plane/Language/common.json#L9:3 Old: Language/preview/2022-10-01-preview/common.json#L9:3 |
|
The new version is missing a definition that was found in the old version. Was 'TemporalSpanResolution' removed or renamed? New: cognitiveservices/data-plane/Language/common.json#L9:3 Old: Language/preview/2022-10-01-preview/common.json#L9:3 |
|
The new version is missing a definition that was found in the old version. Was 'NumericRangeResolution' removed or renamed? New: cognitiveservices/data-plane/Language/common.json#L9:3 Old: Language/preview/2022-10-01-preview/common.json#L9:3 |
|
The new version is missing a definition that was found in the old version. Was 'TemporalModifier' removed or renamed? New: cognitiveservices/data-plane/Language/common.json#L9:3 Old: Language/preview/2022-10-01-preview/common.json#L9:3 |
️️✔️
CredScan succeeded [Detail] [Expand]
There is no credential detected.
️⚠️
LintDiff: 6 Warnings warning [Detail]
compared tags (via openapi-validator v2.0.0) | new version | base version |
---|---|---|
release_2022-07-01-preview | release_2022-07-01-preview(dc50a14) | release_2022-07-01-preview(main) |
release_2022_05_01 | release_2022_05_01(dc50a14) | release_2022_05_01(main) |
release_2022_10_01_preview | release_2022_10_01_preview(dc50a14) | release_2022_10_01_preview(main) |
[must fix]The following errors/warnings are introduced by current PR:
Rule | Message | Related RPC [For API reviewers] |
---|---|---|
Booleans properties are not descriptive in all cases and can make them to use, evaluate whether is makes sense to keep the property as boolean or turn it into an enum. Location: cognitiveservices/data-plane/Language/analyzeconversations.json#L1269 |
||
Property should have a description. Location: cognitiveservices/data-plane/Language/analyzeconversations.json#L1269 |
||
Booleans properties are not descriptive in all cases and can make them to use, evaluate whether is makes sense to keep the property as boolean or turn it into an enum. Location: cognitiveservices/data-plane/Language/analyzetext.json#L2172 |
||
Property should have a description. Location: cognitiveservices/data-plane/Language/analyzetext.json#L2172 |
||
Booleans properties are not descriptive in all cases and can make them to use, evaluate whether is makes sense to keep the property as boolean or turn it into an enum. Location: Language/preview/2022-10-01-preview/analyzetext.json#L2172 |
||
Property should have a description. Location: Language/preview/2022-10-01-preview/analyzetext.json#L2172 |
The following errors/warnings exist before current PR submission:
Only 16 items are listed, please refer to log for more details.
️️✔️
Avocado succeeded [Detail] [Expand]
Validation passes for Avocado.
️️✔️
ApiReadinessCheck succeeded [Detail] [Expand]
️️✔️
~[Staging] ServiceAPIReadinessTest succeeded [Detail] [Expand]
Validation passes for ServiceAPIReadinessTest.
️❌
~[Staging] SwaggerAPIView: 0 Errors, 0 Warnings failed [Detail]
️❌
ModelValidation: 20 Errors, 0 Warnings failed [Detail]
Only 16 items are listed, please refer to log for more details.
️️✔️
SemanticValidation succeeded [Detail] [Expand]
Validation passes for SemanticValidation.
️️✔️
PoliCheck succeeded [Detail] [Expand]
Validation passed for PoliCheck.
️️✔️
PrettierCheck succeeded [Detail] [Expand]
Validation passes for PrettierCheck.
️️✔️
SpellCheck succeeded [Detail] [Expand]
Validation passes for SpellCheck.
️️✔️
Lint(RPaaS) succeeded [Detail] [Expand]
Validation passes for Lint(RPaaS).
️️✔️
CadlValidation succeeded [Detail] [Expand]
Validation passes for CadlValidation.
️️✔️
PR Summary succeeded [Detail] [Expand]
Validation passes for Summary.
Swagger Generation Artifacts
|
Swagger pipeline restarted successfully. If there is ApiView generated, it will be updated in this comment. |
Hi @bidisha-c, one or multiple breaking change(s) is detected in your PR. Please check out the breaking change(s), and provide business justification in the PR comment and @ PR assignee why you must have these change(s), and how external customer impact can be mitigated. Please ensure to follow breaking change policy to request breaking change review and approval before proceeding swagger PR review. |
Hi @bidisha-c, Your PR has some issues. Please fix the CI sequentially by following the order of
|
NewApiVersionRequired reason: |
dev/cognitiveservices/data-plane/Language/analyzeconversations.json
Outdated
Show resolved
Hide resolved
"x-ms-discriminator-value": "OrdinalResolution", | ||
"properties": { | ||
"offset": { | ||
"type": "string", |
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.
Is this should be a numerical value?
"offset": {
"type": "integer",
"description": ".......",
"format": "int32"
},
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.
no this should be a string as existing
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.
Thanks for your answer. Do you have an example or reason for this offset to be a String type?
"description": "The DateTime SubKind" | ||
}, | ||
"value": { | ||
"type": "string", |
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.
should we add the
"format": "date-time"
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.
@mssfang, I was thinking that the "date-time" format should be added to the "TimeExpression" definition instead. However, I haven't confirmed that the service actually returns the right format, which is supposed to be RFC3339 according to the OpenAPI specification 2.0. Do you know if the service returns this correctly?
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.
I think you are right. Btw, do you know what is an example of Set
looks like?
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.
This updates the swagger specs to reflect what the service actually returns.
Explanation of changes per @joseharriaga:
- The
value
property of NumberResolutions must be changed from string to double. - The
ISO4217
(all uppercase) property of CurrencyResolutions must be changed toiso4271
(all lowercase) to match what the service returns in version 2022-10-01-preview. However, this would be a breaking change, because CLU already GA’ed this property. One option is to remove CurrencyResolutions from common.json and have one for CLU (unchanged, all uppercase) and another one for Text Analytics (all lowercase). Then, in the next API version, they can be merged back into the desired state, i.e., a single definition in common.json (all uppsercase). - The possible values of the SpeedUnit enum (some plurals, some singulars) must be changed to match what the service returns in version 2022-10-01-preview (all singulars). Note that the same concerns for breaking changes apply here since CLU already GA’ed this enum too. Additionally, Bidisha mentioned that the desired state is actually all plurals, so the swagger spec can be updated in the next API to match that.
"KilometersPerHour", => KilometerPerHour
"KilometersPerMinute", => KilometerPerMinute
"KilometersPerSecond", => KilometerPerSecond
"MilesPerHour", => MilePerHour
"Knot", => Knot ✅
"FootPerSecond", => FootPerSecond ✅
"FootPerMinute", => FootPerMinute ✅
"YardsPerMinute", => YardPerMinute
"YardsPerSecond", => YardPerSecond
"MetersPerMillisecond", => MeterPerMillisecond
"CentimetersPerMillisecond", => CentimeterPerMillisecond
"KilometersPerMillisecond", => KilometerPerMillisecond
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.
looks good to me! Thank you for answering my questions
At least for CLU .NET, the "ISO" -> "iso" won't be breaking because we don't generate models currently. But why was |
After talking with @kristapratico offline to understand the changes better, I understand this is a correction to what the service returns. From copying and pasting snippets out to diff manually, I see the following changes:
|
Azure#21526) * Duplicate the BaseResolution in analyze-text and analyze-conversations * Address comments
Azure#21526) * Duplicate the BaseResolution in analyze-text and analyze-conversations * Address comments
Data Plane API - Pull Request
Duplicate the BaseResolution in analyze-text and analyze-conversations. The currencyResolution property "ISO4271" has a type mismatch between CLU and NER. Additionally SpeedResolution units values differ.
API Info: The Basics
Most of the information about your service should be captured in the issue that serves as your engagement record.
Is this review for (select one):
Change Scope
This section will help us focus on the specific parts of your API that are new or have been modified.
Please share a link to the design document for the new APIs, a link to the previous Open API document (swagger) if applicable, and the root paths that have been updated.
❔Got questions? Need additional info?? We are here to help!
Contact us!
The Azure API Review Board is dedicated to helping you create amazing APIs. You can read about our mission and learn more about our process on our wiki.
Click here for links to tools, specs, guidelines & other good stuff
Tooling
Guidelines & Specifications
Helpful Links