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

Add Auto Suggest API specification #2635

Closed
wants to merge 9 commits into from

Conversation

jwood803
Copy link

@jwood803 jwood803 commented Mar 10, 2018

Apologies for the WIP pull request, but I'm not exactly sure if I'm on the right track. From my understanding, this is needed to auto-generate the code for the Python Azure SDK.

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

@msftclas
Copy link

msftclas commented Mar 10, 2018

CLA assistant check
All CLA requirements met.

@AutorestCI
Copy link

AutorestCI commented Mar 10, 2018

Automation for azure-sdk-for-go

Nothing to generate for azure-sdk-for-go

@AutorestCI
Copy link

AutorestCI commented Mar 10, 2018

Automation for azure-libraries-for-java

Nothing to generate for azure-libraries-for-java

@AutorestCI
Copy link

AutorestCI commented Mar 10, 2018

Automation for azure-sdk-for-python

Encountered a Subprocess error: (azure-sdk-for-python)

Command: ['/usr/local/bin/autorest', '/tmp/tmp8gma6yyc/rest/specification/cognitiveservices/data-plane/AutoSuggest/readme.md', '--multiapi', '--python', '--python-mode=update', '--python-sdks-folder=/tmp/tmp8gma6yyc/sdk', '[email protected]/autorest.python@~3.0', '--version=preview']
Finished with return code 1
and output:

AutoRest code generation utility [version: 2.0.4262; node: v7.10.1]
(C) 2018 Microsoft Corporation.
https://aka.ms/autorest

There is a new version of AutoRest available (2.0.4280).
 > You can install the newer version with with npm install -g autorest@latest

   Loading AutoRest core      '/root/.autorest/@[email protected]/node_modules/@microsoft.azure/autorest-core/dist' (2.0.4280)
   Loading AutoRest extension '@microsoft.azure/autorest.python' (~3.0->3.0.51)
   Loading AutoRest extension '@microsoft.azure/autorest.modeler' (2.3.44->2.3.44)
ERROR: Referenced file 'file:///tmp/tmp8gma6yyc/rest/specification/cognitiveservices/data-plane/AutoSuggest/stable/v1.0/examples/SuccessfulAutoSuggestRequest.json' not found
    - file:///tmp/tmp8gma6yyc/rest/specification/cognitiveservices/data-plane/AutoSuggest/stable/v1.0/AutoSuggest.json:137:16 ($.paths["/suggestions"].get["x-ms-examples"]["Successful query"]["$ref"])
FATAL: swagger-document/loader - FAILED
FATAL: Error: [OperationAbortedException] Error occurred. Exiting.
Process() cancelled due to exception : [OperationAbortedException] Error occurred. Exiting.

@anuchandy
Copy link
Member

@jwood803 thank you. Just trying to get some context here, saw that you are from Wintellect, are you in touch with anyone from Microsoft cognitive service team? if so can you can tag him/her in this PR so that service team also can take a look. In case you don't know anyone in cognitive team please let me know, i can find the contact and help you to progress this PR. Again thanks for the contribution!

@jwood803
Copy link
Author

Thanks for getting back @anuchandy! I don't know anyone at Microsoft myself, but I'm sure some colleagues of mine do. I can ask them if that works.

Apologies for the noise in this PR. I kind of figured things out as they went. I'm sure I still have some updates here, too. 😄

@anuchandy
Copy link
Member

@jwood803 no worries, i'm checking with cognitive service team to see whether they can take a look at this PR.

``` yaml $(python) && $(python-mode) == 'update'
python:
no-namespace-folders: true
output-folder: $(python-sdks-folder)/azure-cognitiveservices-search-newssearch/azure/cognitiveservices/search/newssearch
Copy link
Member

Choose a reason for hiding this comment

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

Please change "newssearch" for "autosuggest

Copy link
Member

@lmazuel lmazuel left a comment

Choose a reason for hiding this comment

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

Content LGTM, please fix the Python conf. Thanks!

``` yaml $(python) && $(python-mode) == 'create'
python:
basic-setup-py: true
output-folder: $(python-sdks-folder)/azure-cognitiveservices-search-newssearch/azure/cognitiveservices/search/newssearch
Copy link
Member

Choose a reason for hiding this comment

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

Please change "newssearch" for "autosuggest

@lmazuel lmazuel assigned lmazuel and unassigned anuchandy Mar 14, 2018
@AutorestCI
Copy link

AutorestCI commented Mar 14, 2018

Automation for azure-sdk-for-node

Nothing to generate for azure-sdk-for-node

@jwood803
Copy link
Author

Thanks a ton for reviewing @lmazuel! I plan on doing the sample, too, so if I notice anything missing I'll make appropriate updates.

@jwood803 jwood803 changed the title [WIP] Add Auto Suggest API specification Add Auto Suggest API specification Mar 14, 2018
@lmazuel
Copy link
Member

lmazuel commented Mar 15, 2018

@AutorestCI rebuild azure-sdk-for-python

@azuresdkciprbot
Copy link

Hi There,

I am the AutoRest Linter Azure bot. I am here to help. My task is to analyze the situation from the AutoRest linter perspective. Please review the below analysis result:

💡 Please review potentially introduced Error(s)/Warning(s): Analysis Report 💡

File: specification/cognitiveservices/data-plane/AutoSuggest/readme.md
Before the PR: Warning(s): 0 Error(s): 0
After the PR: Warning(s): 0 Error(s): 2

AutoRest Linter Guidelines | AutoRest Linter Issues | Send feedback

Thanks for your co-operation.

@jwood803 jwood803 requested a review from a user March 19, 2018 17:34
@jwood803 jwood803 requested a review from tiffanyachen as a code owner March 19, 2018 17:34
@jwood803 jwood803 requested a review from vladbarosan as a code owner March 19, 2018 17:34
@lmazuel
Copy link
Member

lmazuel commented Mar 20, 2018

@jwood803 Just to give you update, we need someone from the Autosuggest team to sign-off, but your PR looks good to me

@jwood803
Copy link
Author

Thanks a ton, @lmazuel! I think I broke it when fixing the linting errors, but some extra guidance from that team would be very helpful. Thank you again!

@jwood803
Copy link
Author

Looks like I've been slacking too much and this has already been implemented. Should this PR be closed?

@lmazuel
Copy link
Member

lmazuel commented Jun 14, 2018

Hi @jwood803 that's unfortunate, seems the message was lost at some point and indeed the AutoSuggest team worked on it too :(

Did you integrate your Swagger in your applications? Would you mind double-check that this new Swagger checked-in before yours fits your needs? This would be valuable feedback.

Sorry again your contribution didn't make it faster :(

@jwood803
Copy link
Author

No worries, @lmazuel! I should have fixed the issues in this PR a while ago to help it ready for further review. The other PR looks better than mine, too 😄

I would like to implement the samples in the samples repository, but I'm not sure about the workflow before it becomes a Python package in PyPI. I'm guessing after this PR gets merged the Python package gets auto-generated?

@vladbarosan vladbarosan removed their request for review June 15, 2018 00:20
@lmazuel
Copy link
Member

lmazuel commented Jun 15, 2018

@jwood803 Yes, I need to configure the "setup.py" and do some testing, but indeed you got it :)

@jwood803
Copy link
Author

Awesome, @lmazuel, thanks! I'll wait for the package to be generated and I'll hit up some samples! 😃

I'll close this PR, but thank you for all the help! It's much appreciated!

@jwood803 jwood803 closed this Jun 15, 2018
@AutorestCI
Copy link

AutorestCI commented Jun 15, 2018

Automation for azure-sdk-for-ruby

Nothing to generate for azure-sdk-for-ruby

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

6 participants