Skip to content

added missing Swagger#2428

Merged
olydis merged 4 commits into
Azure:masterfrom
gatneil:ops
Mar 20, 2018
Merged

added missing Swagger#2428
olydis merged 4 commits into
Azure:masterfrom
gatneil:ops

Conversation

@gatneil

@gatneil gatneil commented Feb 6, 2018

Copy link
Copy Markdown
Contributor

No description provided.

@azuresdkciprbot

Copy link
Copy Markdown

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:

File: specification/compute/resource-manager/readme.md
Before the PR: Warning(s): 0 Error(s): 39
After the PR: Warning(s): 0 Error(s): 38

AutoRest Linter Guidelines | AutoRest Linter Issues | Send feedback

Thanks for your co-operation.

@AutorestCI

AutorestCI commented Feb 6, 2018

Copy link
Copy Markdown

Automation for azure-sdk-for-python

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-python#1930

@olydis olydis left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

some comments 🙂

"tags": [
"ComputeOperations"
],
"operationId": "ComputeOperations_List",

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

pretty sure it is convention to call this Operations_List; @ravbhatnagar ?

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

yes thats correct

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

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

fix incoming

"paths": {
"/providers/Microsoft.Compute/operations": {
"get": {
"tags": [

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

mark this operation as

    "x-ms-pageable": {
     "nextLinkName": null
    },

to hide the wrapping of ComputeOperationListResult from users. Just to confirm: There are no further pages in the result, i.e. you'll return just one page?

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

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

yup! just one page; fix incoming

"schema": {
"$ref": "#/definitions/AvailabilitySet"
}
}

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

just caught my eye because it's different from the others: this PATCH is not long running?

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

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

nope! it always returns immediately :)

"ComputeOperationListResult": {
"properties": {
"value": {
"type": "array",

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

please mark as readOnly

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

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

fix incoming

"description": "The List Compute Operation operation response."
},
"ComputeOperationValue": {
"properties": {

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

mark all properties as readOnly, same for next type

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

(since they are only ever received from the service, not sent to it)

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

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

fix incoming

@olydis olydis added the WaitForARMFeedback <valid label in PR review process> add this label when ARM review is required label Feb 6, 2018
@olydis

olydis commented Feb 6, 2018

Copy link
Copy Markdown
Contributor

@ravbhatnagar some new operations; I already did a quick SDK-goggles run over it since it's not a lot of changes

@olydis

olydis commented Feb 15, 2018

Copy link
Copy Markdown
Contributor

@ravbhatnagar ping

@ravbhatnagar

Copy link
Copy Markdown
Contributor

Looks good!

@ravbhatnagar ravbhatnagar added ARMSignedOff <valid label in PR review process>add this label when ARM approve updates after review and removed WaitForARMFeedback <valid label in PR review process> add this label when ARM review is required labels Feb 15, 2018
@olydis

olydis commented Feb 20, 2018

Copy link
Copy Markdown
Contributor

@gatneil ping

@AutorestCI

AutorestCI commented Feb 21, 2018

Copy link
Copy Markdown

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#1366

@gatneil

gatneil commented Feb 21, 2018

Copy link
Copy Markdown
Contributor Author

@olydis sorry for the delay; thoughts on the latest and greatest? :)

@Azure Azure deleted a comment from AutorestCI Feb 21, 2018
@lmazuel

lmazuel commented Feb 21, 2018

Copy link
Copy Markdown
Member

@AutorestCI rebuild azure-sdk-for-python

@olydis olydis left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Looking good overall, thanks for the fixes! Just a minor comment 😉

"$ref": "#/definitions/VirtualMachineProperties"
},
"resources": {
"readOnly": true,

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

what does it mean for a property of VirtualMachineUpdate (if I see correctly, only ever sent) to be readOnly? 😃

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

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

Yup, you're right. It makes no sense, so I removed it. Originally, I copied that from the VirtualMachine object, which is used in GETs as well, so it makes sense to have it in that object as readOnly, but it doesn't make sense for the VirtualMachineUpdate object :)

@lmazuel

lmazuel commented Mar 13, 2018

Copy link
Copy Markdown
Member

@AutorestCI rebuild azure-sdk-for-python

@jhendrixMSFT

Copy link
Copy Markdown
Member

@AutorestCI rebuild azure-sdk-for-go

@AutorestCI

Copy link
Copy Markdown
Encountered a Subprocess error

Command: ['/usr/local/bin/autorest', '/tmp/tmpekhqdq7p/rest/specification/compute/resource-manager/readme.md', '--go', '--go-sdk-folder=/tmp/tmpekhqdq7p/sdk', '--multiapi', '--package-version=latest', '--use=@microsoft.azure/autorest.go@~2.1.87', "--user-agent='Azure-SDK-For-Go/latest services'", '--verbose']
Finished with return code 1
and output:

AutoRest code generation utility [version: 2.0.4255; node: v7.10.1]
(C) 2018 Microsoft Corporation.
https://aka.ms/autorest
   Loading AutoRest core      '/tmp/.autorest/@microsoft.azure_autorest-core@2.0.4255/node_modules/@microsoft.azure/autorest-core/dist' (2.0.4255)
   Loading AutoRest extension '@microsoft.azure/autorest.go' (~2.1.87->2.1.88)
   Loading AutoRest extension '@microsoft.azure/autorest.modeler' (2.3.38->2.3.38)
Processing batch task - {"tag":"package-disks-2018-04"} .
Processing batch task - {"tag":"package-2017-12"} .
FATAL: System.InvalidOperationException: Swagger document contains two or more x-ms-enum extensions with the same name 'StorageAccountTypes' and different values: Standard_LRS,Premium_LRS vs. Standard_LRS,Premium_LRS
   at AutoRest.Modeler.ObjectBuilder.BuildServiceType(String serviceTypeName, Boolean required) in C:\Users\ci\AppData\Local\Temp\PUBLISH8kiit\38_20171116T010915\autorest.modeler\src\ObjectBuilder.cs:line 147
   at AutoRest.Modeler.SchemaBuilder.ParentBuildServiceType(String serviceTypeName, Boolean required) in C:\Users\ci\AppData\Local\Temp\PUBLISH8kiit\38_20171116T010915\autorest.modeler\src\SchemaBuilder.cs:line 204
   at AutoRest.Modeler.SchemaBuilder.BuildServiceType(String serviceTypeName, Boolean required) in C:\Users\ci\AppData\Local\Temp\PUBLISH8kiit\38_20171116T010915\autorest.modeler\src\SchemaBuilder.cs:line 46
   at AutoRest.Modeler.SchemaBuilder.BuildServiceType(String serviceTypeName, Boolean required) in C:\Users\ci\AppData\Local\Temp\PUBLISH8kiit\38_20171116T010915\autorest.modeler\src\SchemaBuilder.cs:line 131
   at AutoRest.Modeler.SchemaBuilder.BuildServiceType(String serviceTypeName, Boolean required) in C:\Users\ci\AppData\Local\Temp\PUBLISH8kiit\38_20171116T010915\autorest.modeler\src\SchemaBuilder.cs:line 131
   at AutoRest.Modeler.SwaggerModeler.BuildCompositeTypes() in C:\Users\ci\AppData\Local\Temp\PUBLISH8kiit\38_20171116T010915\autorest.modeler\src\SwaggerModeler.cs:line 271
   at AutoRest.Modeler.SwaggerModeler.Build(ServiceDefinition serviceDefinition) in C:\Users\ci\AppData\Local\Temp\PUBLISH8kiit\38_20171116T010915\autorest.modeler\src\SwaggerModeler.cs:line 66
   at AutoRest.Modeler.Program.<ProcessInternal>d__2.MoveNext() in C:\Users\ci\AppData\Local\Temp\PUBLISH8kiit\38_20171116T010915\autorest.modeler\src\Program.cs:line 60
--- End of stack trace from previous location where exception was thrown ---
   at System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw()
   at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)
   at NewPlugin.<Process>d__15.MoveNext()
FATAL: go/imodeler1 - FAILED
FATAL: Error: Plugin imodeler1 reported failure.
Process() cancelled due to exception : Plugin imodeler1 reported failure.
Failure during batch task - {"tag":"package-2017-12"} -- Error: Plugin imodeler1 reported failure..
  Error: Plugin imodeler1 reported failure.

@gatneil gatneil requested a review from a user March 20, 2018 02:47
@AutorestCI

AutorestCI commented Mar 20, 2018

Copy link
Copy Markdown

Automation for azure-sdk-for-node

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

@AutorestCI

AutorestCI commented Mar 20, 2018

Copy link
Copy Markdown

Automation for azure-libraries-for-java

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

@gatneil

gatneil commented Mar 20, 2018

Copy link
Copy Markdown
Contributor Author

@olydis thanks for your patience! How's it look now? :)

@olydis olydis left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

LGTM

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

ARMSignedOff <valid label in PR review process>add this label when ARM approve updates after review Reviewed-FeedbackProvided

Projects

None yet

Development

Successfully merging this pull request may close these issues.

7 participants