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

ComputerVision - collection of fixes #3145

Merged
merged 1 commit into from
Jun 5, 2018
Merged

Conversation

cthrash
Copy link
Contributor

@cthrash cthrash commented May 29, 2018

  • fix ocr language parameter to fix bug
  • language parameter missing for /tag path
  • language parameter missing for /models/*/analyze path
  • make /models/*/analyze return a more generic type
  • add specific types for /models/*/analyze to return for current models

This checklist is used to make sure that common issues in a pull request are addressed. This will expedite the process of getting your pull request merged and avoid extra work on your part to fix issues discovered during the review process.

PR information

  • The title of the PR is clear and informative.
  • There are a small number of commits, each of which have an informative message. This means that previously merged commits do not appear in the history of the PR. For information on cleaning up the commits in your pull request, see this page.
  • Except for special cases involving multiple contributors, the PR is started from a fork of the main repository, not a branch.
  • If applicable, the PR references the bug/issue that it fixes.
  • Swagger files are correctly named (e.g. the api-version in the path should match the api-version in the spec).

Quality of Swagger

* fix ocr language parameter to fix [bug](Azure/azure-sdk-for-net#4083)
* language parameter missing for /tag path
* language parameter missing for /models/*/analyze path
* make /models/*/analyze return a more generic type
* add specific types for /models/*/analyze to return for current models
@AutorestCI
Copy link

AutorestCI commented May 29, 2018

Automation for azure-sdk-for-python

The initial PR has been merged into your service PR:
Azure/azure-sdk-for-python#2614

@AutorestCI
Copy link

AutorestCI commented May 29, 2018

Automation for azure-libraries-for-java

The initial PR has been merged into your service PR:
AutorestCI/azure-libraries-for-java#190

@AutorestCI
Copy link

AutorestCI commented May 29, 2018

Automation for azure-sdk-for-node

The initial PR has been merged into your service PR:
Azure/azure-sdk-for-node#2901

@AutorestCI
Copy link

AutorestCI commented May 29, 2018

Automation for azure-sdk-for-ruby

The initial PR has been merged into your service PR:
Azure/azure-sdk-for-ruby#1349

@AutorestCI
Copy link

AutorestCI commented May 29, 2018

Automation for azure-sdk-for-go

A PR has been created for you based on this PR content.

Once this PR will be merged, content will be added to your service PR:
Azure/azure-sdk-for-go#1966

@cthrash
Copy link
Contributor Author

cthrash commented May 31, 2018

It's difficult to tell if Travis is having issues, but the breaking change is intentional. The OcrResult type was incorrect and un-serializable.

"Landmarks"
]
"type": "string"
},
Copy link
Member

Choose a reason for hiding this comment

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

Any specific reason to use raw string instead of enum? Are we are doing this to ensure customer can use SDK with content values those are not listed as known enum values (Celebrities, Landmarks)? If yes, then we could simply change "modelAsString": false to "modelAsString": true.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Today we only have two custom (domain) models, but we want to reserve the right to add one without requiring a client SDK refresh. There's a method (/model) that will return the permissible values. Note that the hand-crafted version only takes a string.

@@ -895,7 +895,8 @@
"type": "object",
"properties": {
"language": {
"$ref": "#/definitions/OcrResult"
"type": "string",
"description": "The BCP-47 language code of the text in the image."
Copy link
Member

Choose a reason for hiding this comment

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

is this a breaking change in the server side? i.e. returning string instead of complex type?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

No the server for this type is unchanged for 2+ years. The swagger was just wrong.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

A bit of background - up to now most of our customers have been using a hand-built .net client SDK. We're bringing the swagger to par so that this will be the official package source moving forward.

Copy link
Member

Choose a reason for hiding this comment

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

@cthrash thank you Chris for clarifying.

@cthrash
Copy link
Contributor Author

cthrash commented Jun 4, 2018

Are there more changes required?

@anuchandy
Copy link
Member

@cthrash merging this.

@anuchandy anuchandy merged commit 91ed1c0 into Azure:master Jun 5, 2018
@cthrash cthrash deleted the api-cleanup branch June 13, 2018 17:47
mccleanp pushed a commit that referenced this pull request Mar 23, 2022
[Communication] Fix linter validation errors and blocking GA issues
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

OcrResult variable Language of the wrong type.
3 participants