Skip to content

Add Go SDK generation config#3403

Merged
vladbarosan merged 3 commits intomasterfrom
securityGoSDK
Jul 24, 2018
Merged

Add Go SDK generation config#3403
vladbarosan merged 3 commits intomasterfrom
securityGoSDK

Conversation

@vladbarosan
Copy link
Copy Markdown

@vladbarosan vladbarosan commented Jul 11, 2018

No description provided.

@AutorestCI
Copy link
Copy Markdown

AutorestCI commented Jul 11, 2018

Automation for azure-sdk-for-python

Nothing to generate for azure-sdk-for-python

@vladbarosan
Copy link
Copy Markdown
Author

Fixes Azure/azure-sdk-for-go#1246

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

Copy/paste error.

@AutorestCI
Copy link
Copy Markdown

AutorestCI commented Jul 11, 2018

Automation for azure-sdk-for-ruby

Nothing to generate for azure-sdk-for-ruby

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

If you fix the namespace value you can replace the hard-coded security path/namespace with $(namespace). One day I'd like to see the API version be defined along with a tag so we don't have to duplicate it here.

@AutorestCI
Copy link
Copy Markdown

AutorestCI commented Jul 11, 2018

Automation for azure-sdk-for-go

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

Command: ['/usr/local/bin/autorest', '/tmp/tmposhukyk_/rest/specification/security/resource-manager/readme.md', '--go', '--go-sdk-folder=/tmp/tmposhukyk_/src/github.com/Azure/azure-sdk-for-go', '--multiapi', '--use=@microsoft.azure/autorest.go@~2.1.108', '--use-onever', '--verbose']
Finished with return code 1
and output:

AutoRest code generation utility [version: 2.0.4280; node: v8.11.3]
(C) 2018 Microsoft Corporation.
https://aka.ms/autorest

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

   Loading AutoRest core      '/root/.autorest/@microsoft.azure_autorest-core@2.0.4280/node_modules/@microsoft.azure/autorest-core/dist' (2.0.4280)
   Including configuration file 'file:///tmp/tmposhukyk_/rest/specification/security/resource-manager/readme.go.md'
   Loading AutoRest extension '@microsoft.azure/autorest.go' (~2.1.108->2.1.108)
   Loading AutoRest extension '@microsoft.azure/autorest.modeler' (2.3.38->2.3.38)
Processing batch task - {"tag":"package-composite-v1"} .
   Including configuration file 'file:///tmp/tmposhukyk_/rest/specification/security/resource-manager/readme.go.md'
FATAL: System.InvalidOperationException: Found incompatible property types ,  for property 'properties' in schema inheritance chain
   at AutoRest.Modeler.SchemaResolver.ExpandAllOf(Schema schema) in C:\Users\ci\AppData\Local\Temp\PUBLISH8kiit\38_20171116T010915\autorest.modeler\src\SchemaResolver.cs:line 157
   at AutoRest.Modeler.SchemaResolver.Unwrap(Schema schema) in C:\Users\ci\AppData\Local\Temp\PUBLISH8kiit\38_20171116T010915\autorest.modeler\src\SchemaResolver.cs:line 75
   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 35
   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-composite-v1"} -- Error: Plugin imodeler1 reported failure..
  Error: Plugin imodeler1 reported failure.

@AutorestCI
Copy link
Copy Markdown

AutoRest linter results for ARM Related Validation Errors/Warnings

These errors are reported by the ARM team's validation tools, reachout to ARM RP API Review directly for any questions or concerns.

File: specification/security/resource-manager/readme.md

⚠️0 new Warnings.(1 total)
0 new Errors.(0 total)

AutoRest Linter Guidelines | AutoRest Linter Issues | Send feedback

Thanks for your co-operation.

@AutorestCI
Copy link
Copy Markdown

AutoRest linter results for SDK Related Validation Errors/Warnings

These errors are reported by the SDK team's validation tools, reachout to ADX Swagger Reviewers directly for any questions or concerns.

File: specification/security/resource-manager/readme.md

⚠️0 new Warnings.(76 total)
0 new Errors.(0 total)

AutoRest Linter Guidelines | AutoRest Linter Issues | Send feedback

Thanks for your co-operation.

@AutorestCI
Copy link
Copy Markdown

AutorestCI commented Jul 11, 2018

Automation for azure-sdk-for-node

Nothing to generate for azure-sdk-for-node

@AutorestCI
Copy link
Copy Markdown

AutorestCI commented Jul 11, 2018

Automation for azure-sdk-for-java

Nothing to generate for azure-sdk-for-java

@AutorestCI
Copy link
Copy Markdown

AutoRest linter results for SDK Related Validation Errors/Warnings

These errors are reported by the SDK team's validation tools, reachout to ADX Swagger Reviewers directly for any questions or concerns.

File: specification/security/resource-manager/readme.md

⚠️0 new Warnings.(76 total)
0 new Errors.(0 total)

AutoRest Linter Guidelines | AutoRest Linter Issues | Send feedback

Thanks for your co-operation.

@AutorestCI
Copy link
Copy Markdown

AutoRest linter results for ARM Related Validation Errors/Warnings

These errors are reported by the ARM team's validation tools, reachout to ARM RP API Review directly for any questions or concerns.

File: specification/security/resource-manager/readme.md

⚠️0 new Warnings.(1 total)
0 new Errors.(0 total)

AutoRest Linter Guidelines | AutoRest Linter Issues | Send feedback

Thanks for your co-operation.

@vladbarosan
Copy link
Copy Markdown
Author

@chlahav there seems to be a problem with the swagger, are the 2 api version specs compatible ?
The following error shows up when trying to generate the Go SDK:
FATAL: System.InvalidOperationException: Found incompatible property types , for property 'properties' in schema inheritance chain

@lmazuel
Copy link
Copy Markdown
Member

lmazuel commented Jul 11, 2018

@vladbarosan We try to move to language configuration in its own file readme.go.md. Could it be done this way? Thanks!
Not critical.
Example:
https://github.com/Azure/azure-rest-api-specs/blob/master/specification/cdn/resource-manager/readme.go.md

@vladbarosan
Copy link
Copy Markdown
Author

@lmazuel sure will update either wont merge until the generation actually works

@AutorestCI
Copy link
Copy Markdown

AutoRest linter results for ARM Related Validation Errors/Warnings

These errors are reported by the ARM team's validation tools, reachout to ARM RP API Review directly for any questions or concerns.

File: specification/security/resource-manager/readme.md

⚠️0 new Warnings.(1 total)
0 new Errors.(0 total)

AutoRest Linter Guidelines | AutoRest Linter Issues | Send feedback

Thanks for your co-operation.

@AutorestCI
Copy link
Copy Markdown

AutoRest linter results for SDK Related Validation Errors/Warnings

These errors are reported by the SDK team's validation tools, reachout to ADX Swagger Reviewers directly for any questions or concerns.

File: specification/security/resource-manager/readme.md

⚠️0 new Warnings.(74 total)
0 new Errors.(0 total)

AutoRest Linter Guidelines | AutoRest Linter Issues | Send feedback

Thanks for your co-operation.

@AutorestCI
Copy link
Copy Markdown

AutoRest linter results for ARM Related Validation Errors/Warnings

These errors are reported by the ARM team's validation tools, reachout to ARM RP API Review directly for any questions or concerns.

File: specification/security/resource-manager/readme.md

⚠️0 new Warnings.(1 total)
0 new Errors.(0 total)

AutoRest Linter Guidelines | AutoRest Linter Issues | Send feedback

Thanks for your co-operation.

@AutorestCI
Copy link
Copy Markdown

AutoRest linter results for SDK Related Validation Errors/Warnings

These errors are reported by the SDK team's validation tools, reachout to ADX Swagger Reviewers directly for any questions or concerns.

File: specification/security/resource-manager/readme.md

⚠️0 new Warnings.(74 total)
0 new Errors.(0 total)

AutoRest Linter Guidelines | AutoRest Linter Issues | Send feedback

Thanks for your co-operation.

@vladbarosan
Copy link
Copy Markdown
Author

@lmazuel is there a way to re trigger the go generation to see if it works ?

@lmazuel
Copy link
Copy Markdown
Member

lmazuel commented Jul 16, 2018

@AutorestCI rebuild azure-sdk-for-go

@AutorestCI
Copy link
Copy Markdown

Encountered a Subprocess error

Command: ['/usr/local/bin/autorest', '/tmp/tmpyk8g9yg0/rest/specification/security/resource-manager/readme.md', '--go', '--go-sdk-folder=/tmp/tmpyk8g9yg0/src/github.com/Azure/azure-sdk-for-go', '--multiapi', '--use=@microsoft.azure/autorest.go@~2.1.105', '--use-onever', '--verbose']
Finished with return code 1
and output:

AutoRest code generation utility [version: 2.0.4280; node: v8.11.3]
(C) 2018 Microsoft Corporation.
https://aka.ms/autorest
   Loading AutoRest core      '/root/.autorest/@microsoft.azure_autorest-core@2.0.4280/node_modules/@microsoft.azure/autorest-core/dist' (2.0.4280)
   Including configuration file 'file:///tmp/tmpyk8g9yg0/rest/specification/security/resource-manager/readme.go.md'
   Loading AutoRest extension '@microsoft.azure/autorest.go' (~2.1.105->2.1.105)
   Loading AutoRest extension '@microsoft.azure/autorest.modeler' (2.3.38->2.3.38)
Processing batch task - {"tag":"package-composite-v1"} .
   Including configuration file 'file:///tmp/tmpyk8g9yg0/rest/specification/security/resource-manager/readme.go.md'
FATAL: System.InvalidOperationException: Found incompatible property types ,  for property 'properties' in schema inheritance chain
   at AutoRest.Modeler.SchemaResolver.ExpandAllOf(Schema schema) in C:\Users\ci\AppData\Local\Temp\PUBLISH8kiit\38_20171116T010915\autorest.modeler\src\SchemaResolver.cs:line 157
   at AutoRest.Modeler.SchemaResolver.Unwrap(Schema schema) in C:\Users\ci\AppData\Local\Temp\PUBLISH8kiit\38_20171116T010915\autorest.modeler\src\SchemaResolver.cs:line 75
   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 35
   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-composite-v1"} -- Error: Plugin imodeler1 reported failure..
  Error: Plugin imodeler1 reported failure.

@lmazuel
Copy link
Copy Markdown
Member

lmazuel commented Jul 16, 2018

@vladbarosan it seems it doesn't :(
(if you didn't notice, you can click on "Encountered a Subprocess error" to get the full trace)

@vladbarosan
Copy link
Copy Markdown
Author

vladbarosan commented Jul 16, 2018

@lmazuel thanks for the command. Yes I noticed the problem is that it seems to be a modeler error which seems to point to a swagger issue FATAL: System.InvalidOperationException: Found incompatible property types , for property 'properties' in schema inheritance chain. @chlahav can you help here ?

@vladbarosan
Copy link
Copy Markdown
Author

Merging and #3453 should fix generation issues

@vladbarosan vladbarosan merged commit c0cbb2c into master Jul 24, 2018
@vladbarosan vladbarosan deleted the securityGoSDK branch October 29, 2018 20:40
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.

5 participants