Skip to content

Draft: getLatestVersionName test branch #24688

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

Draft
wants to merge 1 commit into
base: feature/cplat-2022-08-03-2nd
Choose a base branch
from

Conversation

Sandido
Copy link
Contributor

@Sandido Sandido commented Jul 3, 2023

ARM (Control Plane) API Specification Update Pull Request

Purpose of this PR

What's the purpose of this PR? Check all that apply. This is mandatory!

Copy of this PR for test purposes: https://github.com/Azure/azure-rest-api-specs/pull/23633/files

  • New API version. (Such PR should have been generated with OpenAPI Hub, per this wiki doc.)
  • Update existing version for a new feature. (This is applicable only when you are revising a private preview API version.)
  • Update existing version to fix swagger quality issues in S360.
  • Other, please clarify:
    • edit this with your clarification

Due diligence checklist

To merge this PR, you must go through the following checklist and confirm you understood
and followed the instructions by checking all the boxes:

ARM API changes review

  • If you want for the ARM team to review this PR, you must add the ARMReview label.
  • The automation may automatically add the ARMReview label, if appropriate.
    If this happens, proceed according to guidance given in GitHub comments also added by the automation.

Breaking change review

If you have any breaking changes as defined in the Breaking Change Policy,
follow the process outlined in the High-level Breaking Change Process doc.

Getting help

@openapi-workflow-bot
Copy link

Hi, @Sandido! Thank you for your pull request. To help get your PR merged:
- Ensure you reviewed the checklists in the PR description. - Know that PR assignee is the person auto-assigned and responsible for your current PR review and approval. - For convenient view of the API changes made by this PR, refer to the URLs provided in the table in
the Generated ApiView comment added to this PR. You can use ApiView to show API versions diff.

@openapi-pipeline-app
Copy link

openapi-pipeline-app bot commented Jul 3, 2023

Swagger Validation Report

️️✔️BreakingChange succeeded [Detail] [Expand]
There are no breaking changes.
️⚠️Breaking Change(Cross-Version): 18 Warnings warning [Detail]
compared swaggers (via Oad v0.10.4)] new version base version
gallery.json 2022-08-03(a93d53c) 2022-03-03(main)
gallery.json 2022-08-03(a93d53c) 2020-09-30(main)

The following breaking changes are detected by comparison with the latest preview version:

Rule Message
⚠️ 1017 - ReferenceRedirection The '$ref' property points to different models in the old and new versions.
New: GalleryRP/stable/2022-08-03/gallery.json#L1830:9
Old: GalleryRP/preview/2020-09-30/gallery.json#L1736:9
⚠️ 1017 - ReferenceRedirection The '$ref' property points to different models in the old and new versions.
New: GalleryRP/stable/2022-08-03/gallery.json#L2414:9
Old: GalleryRP/preview/2020-09-30/gallery.json#L2106:9
⚠️ 1017 - ReferenceRedirection The '$ref' property points to different models in the old and new versions.
New: GalleryRP/stable/2022-08-03/gallery.json#L2472:9
Old: GalleryRP/preview/2020-09-30/gallery.json#L2251:9
⚠️ 1017 - ReferenceRedirection The '$ref' property points to different models in the old and new versions.
New: GalleryRP/stable/2022-08-03/gallery.json#L2775:9
Old: GalleryRP/preview/2020-09-30/gallery.json#L2439:9
⚠️ 1017 - ReferenceRedirection The '$ref' property points to different models in the old and new versions.
New: GalleryRP/stable/2022-08-03/gallery.json#L2865:9
Old: GalleryRP/preview/2020-09-30/gallery.json#L2515:9
⚠️ 1017 - ReferenceRedirection The '$ref' property points to different models in the old and new versions.
New: GalleryRP/stable/2022-08-03/gallery.json#L2865:9
Old: GalleryRP/preview/2020-09-30/gallery.json#L2515:9
⚠️ 1017 - ReferenceRedirection The '$ref' property points to different models in the old and new versions.
New: GalleryRP/stable/2022-08-03/gallery.json#L2128:9
Old: GalleryRP/preview/2020-09-30/gallery.json#L1917:9
⚠️ 1017 - ReferenceRedirection The '$ref' property points to different models in the old and new versions.
New: GalleryRP/stable/2022-08-03/gallery.json#L2865:9
Old: GalleryRP/preview/2020-09-30/gallery.json#L2515:9
⚠️ 1032 - DifferentAllOf The new version has a different 'allOf' property than the previous one.
New: GalleryRP/stable/2022-08-03/gallery.json#L2775:9
Old: GalleryRP/preview/2020-09-30/gallery.json#L2439:9
⚠️ 1032 - DifferentAllOf The new version has a different 'allOf' property than the previous one.
New: GalleryRP/stable/2022-08-03/gallery.json#L2865:9
Old: GalleryRP/preview/2020-09-30/gallery.json#L2515:9
⚠️ 1032 - DifferentAllOf The new version has a different 'allOf' property than the previous one.
New: GalleryRP/stable/2022-08-03/gallery.json#L2865:9
Old: GalleryRP/preview/2020-09-30/gallery.json#L2515:9
⚠️ 1032 - DifferentAllOf The new version has a different 'allOf' property than the previous one.
New: GalleryRP/stable/2022-08-03/gallery.json#L2865:9
Old: GalleryRP/preview/2020-09-30/gallery.json#L2515:9
⚠️ 1033 - RemovedProperty The new version is missing a property found in the old version. Was 'uri' renamed or removed?
New: GalleryRP/stable/2022-08-03/gallery.json#L2796:7
Old: GalleryRP/preview/2020-09-30/gallery.json#L2456:7
⚠️ 1033 - RemovedProperty The new version is missing a property found in the old version. Was 'uri' renamed or removed?
New: GalleryRP/stable/2022-08-03/gallery.json#L2810:7
Old: GalleryRP/preview/2020-09-30/gallery.json#L2456:7
⚠️ 1048 - AddedXmsEnum The new version adds a x-ms-enum extension.
New: GalleryRP/stable/2022-08-03/gallery.json#L1830:9
Old: GalleryRP/preview/2020-09-30/gallery.json#L1736:9
⚠️ 1048 - AddedXmsEnum The new version adds a x-ms-enum extension.
New: GalleryRP/stable/2022-08-03/gallery.json#L2414:9
Old: GalleryRP/preview/2020-09-30/gallery.json#L2106:9
⚠️ 1048 - AddedXmsEnum The new version adds a x-ms-enum extension.
New: GalleryRP/stable/2022-08-03/gallery.json#L2472:9
Old: GalleryRP/preview/2020-09-30/gallery.json#L2251:9
⚠️ 1048 - AddedXmsEnum The new version adds a x-ms-enum extension.
New: GalleryRP/stable/2022-08-03/gallery.json#L2128:9
Old: GalleryRP/preview/2020-09-30/gallery.json#L1917:9
️❌LintDiff: 2 Errors, 2 Warnings failed [Detail]
compared tags (via openapi-validator v2.1.3) new version base version
package-2022-08-03 package-2022-08-03(a93d53c) package-2022-08-03(feature/cplat-2022-08-03-2nd)

[must fix]The following errors/warnings are introduced by current PR:

Rule Message Related RPC [For API reviewers]
PathForNestedResource The path for nested resource doest not meet the valid resource pattern.
Location: GalleryRP/stable/2022-08-03/gallery.json#L848
RPC-Uri-V1-06,RPC-Put-V1-02
GetCollectionOnlyHasValueAndNextLink Get endpoints for collections of resources must only have the value and nextLink properties in their model.
Location: GalleryRP/stable/2022-08-03/gallery.json#L885
⚠️ ParameterNotDefinedInGlobalParameters Parameter 'api-version' is referenced but not defined in the global parameters section of Service Definition
Location: GalleryRP/stable/2022-08-03/gallery.json#L855
⚠️ ParameterNotUsingCommonTypes Not using the common-types defined parameter 'resourceGroupName'.
Location: GalleryRP/stable/2022-08-03/gallery.json#L855


The following errors/warnings exist before current PR submission:

Only 30 items are listed, please refer to log for more details.

Rule Message
ResourceNameRestriction The resource name parameter 'galleryName' should be defined with a 'pattern' restriction.
Location: GalleryRP/stable/2022-08-03/gallery.json#L37
PutResponseSchemaDescription Description of 200 response code of a PUT operation MUST include term 'update'.
Location: GalleryRP/stable/2022-08-03/gallery.json#L71
LroLocationHeader A 202 response should include an Location response header.
Location: GalleryRP/stable/2022-08-03/gallery.json#L84
LroErrorContent Error response content of long running operations must follow the error schema provided in the common types v2 and above.
Location: GalleryRP/stable/2022-08-03/gallery.json#L93
PatchResponseCode LRO PATCH must have 200 and 202 return codes.
Location: GalleryRP/stable/2022-08-03/gallery.json#L113
LroPatch202 The async patch operation should return 202.
Location: GalleryRP/stable/2022-08-03/gallery.json#L146
LroErrorContent Error response content of long running operations must follow the error schema provided in the common types v2 and above.
Location: GalleryRP/stable/2022-08-03/gallery.json#L156
ParametersInPointGet Query parameter $select should be removed. Point Get's MUST not have query parameters other than api version.
Location: GalleryRP/stable/2022-08-03/gallery.json#L173
ParametersInPointGet Query parameter $expand should be removed. Point Get's MUST not have query parameters other than api version.
Location: GalleryRP/stable/2022-08-03/gallery.json#L173
LroLocationHeader A 202 response should include an Location response header.
Location: GalleryRP/stable/2022-08-03/gallery.json#L265
LroErrorContent Error response content of long running operations must follow the error schema provided in the common types v2 and above.
Location: GalleryRP/stable/2022-08-03/gallery.json#L274
ResourceNameRestriction The resource name parameter 'galleryName' should be defined with a 'pattern' restriction.
Location: GalleryRP/stable/2022-08-03/gallery.json#L286
ResourceNameRestriction The resource name parameter 'galleryImageName' should be defined with a 'pattern' restriction.
Location: GalleryRP/stable/2022-08-03/gallery.json#L286
PutResponseSchemaDescription Description of 200 response code of a PUT operation MUST include term 'update'.
Location: GalleryRP/stable/2022-08-03/gallery.json#L327
LroLocationHeader A 202 response should include an Location response header.
Location: GalleryRP/stable/2022-08-03/gallery.json#L340
LroErrorContent Error response content of long running operations must follow the error schema provided in the common types v2 and above.
Location: GalleryRP/stable/2022-08-03/gallery.json#L349
PatchResponseCode LRO PATCH must have 200 and 202 return codes.
Location: GalleryRP/stable/2022-08-03/gallery.json#L360
LroPatch202 The async patch operation should return 202.
Location: GalleryRP/stable/2022-08-03/gallery.json#L400
LroErrorContent Error response content of long running operations must follow the error schema provided in the common types v2 and above.
Location: GalleryRP/stable/2022-08-03/gallery.json#L410
LroLocationHeader A 202 response should include an Location response header.
Location: GalleryRP/stable/2022-08-03/gallery.json#L507
LroErrorContent Error response content of long running operations must follow the error schema provided in the common types v2 and above.
Location: GalleryRP/stable/2022-08-03/gallery.json#L516
ResourceNameRestriction The resource name parameter 'galleryName' should be defined with a 'pattern' restriction.
Location: GalleryRP/stable/2022-08-03/gallery.json#L528
ResourceNameRestriction The resource name parameter 'galleryImageName' should be defined with a 'pattern' restriction.
Location: GalleryRP/stable/2022-08-03/gallery.json#L528
ResourceNameRestriction The resource name parameter 'galleryImageVersionName' should be defined with a 'pattern' restriction.
Location: GalleryRP/stable/2022-08-03/gallery.json#L528
PutResponseSchemaDescription Description of 200 response code of a PUT operation MUST include term 'update'.
Location: GalleryRP/stable/2022-08-03/gallery.json#L576
LroLocationHeader A 202 response should include an Location response header.
Location: GalleryRP/stable/2022-08-03/gallery.json#L589
LroErrorContent Error response content of long running operations must follow the error schema provided in the common types v2 and above.
Location: GalleryRP/stable/2022-08-03/gallery.json#L598
PatchResponseCode LRO PATCH must have 200 and 202 return codes.
Location: GalleryRP/stable/2022-08-03/gallery.json#L633
LroPatch202 The async patch operation should return 202.
Location: GalleryRP/stable/2022-08-03/gallery.json#L680
LroErrorContent Error response content of long running operations must follow the error schema provided in the common types v2 and above.
Location: GalleryRP/stable/2022-08-03/gallery.json#L690
️⚠️Avocado: 1 Warnings warning [Detail]
Rule Message
⚠️ MULTIPLE_API_VERSION The default tag contains multiple API versions swaggers.
readme: specification/compute/resource-manager/readme.md
tag: specification/compute/resource-manager/readme.md#tag-package-2022-08-03
️️✔️SwaggerAPIView succeeded [Detail] [Expand]
️️✔️CadlAPIView succeeded [Detail] [Expand]
️️✔️TypeSpecAPIView succeeded [Detail] [Expand]
️️✔️ModelValidation succeeded [Detail] [Expand]
Validation passes for ModelValidation.
️️✔️SemanticValidation succeeded [Detail] [Expand]
Validation passes for SemanticValidation.
️❌PrettierCheck: 1 Errors, 0 Warnings failed [Detail]
Rule Message
HowToFix Code style issues found
path: 2022-08-03/examples/galleryExamples/GalleryImageVersion_Get_LatestVersionName.json
️️✔️SpellCheck succeeded [Detail] [Expand]
Validation passes for SpellCheck.
️️✔️CadlValidation succeeded [Detail] [Expand]
Validation passes for CadlValidation.
️️✔️TypeSpec Validation succeeded [Detail] [Expand]
Validation passes for TypeSpec Validation.
️️✔️PR Summary succeeded [Detail] [Expand]
Validation passes for Summary.
Posted by Swagger Pipeline | How to fix these errors?

@openapi-pipeline-app
Copy link

openapi-pipeline-app bot commented Jul 3, 2023

Swagger Generation Artifacts

️️✔️ApiDocPreview succeeded [Detail] [Expand]
 Please click here to preview with your @microsoft account. 
️️✔️SDK Breaking Change Tracking succeeded [Detail] [Expand]

Breaking Changes Tracking




️️✔️ azure-sdk-for-net-track2 succeeded [Detail] [Expand]
️⚠️ azure-sdk-for-python-track2 warning [Detail]
  • ⚠️Warning [Logs] Generate from 44947c7. SDK Automation 14.0.0
    command	sh scripts/automation_init.sh ../azure-sdk-for-python_tmp/initInput.json ../azure-sdk-for-python_tmp/initOutput.json
    cmderr	[automation_init.sh] WARNING: Skipping azure-nspkg as it is not installed.
    command	sh scripts/automation_generate.sh ../azure-sdk-for-python_tmp/generateInput.json ../azure-sdk-for-python_tmp/generateOutput.json
    cmderr	[automation_generate.sh]  notice
    cmderr	[automation_generate.sh] npm notice New minor version of npm available! 9.5.1 -> 9.7.2
    cmderr	[automation_generate.sh] npm notice Changelog: <https://github.com/npm/cli/releases/tag/v9.7.2>
    cmderr	[automation_generate.sh] npm notice Run `npm install -g [email protected]` to update!
    cmderr	[automation_generate.sh] npm notice
  • ️✔️track2_azure-mgmt-compute [View full logs]  [Preview SDK Changes]
    info	[Changelog] ### Features Added
    info	[Changelog]
    info	[Changelog]   - Added model CommunityGalleryImageIdentifier
    info	[Changelog]   - Added model EdgeZoneStorageAccountType
️⚠️ azure-sdk-for-java warning [Detail]
️️✔️ azure-sdk-for-js succeeded [Detail] [Expand]
  • ️✔️Succeeded [Logs] Generate from 44947c7. SDK Automation 14.0.0
    command	sh .scripts/automation_init.sh ../azure-sdk-for-js_tmp/initInput.json ../azure-sdk-for-js_tmp/initOutput.json
    warn	File azure-sdk-for-js_tmp/initOutput.json not found to read
    command	sh .scripts/automation_generate.sh ../azure-sdk-for-js_tmp/generateInput.json ../azure-sdk-for-js_tmp/generateOutput.json
  • ️✔️@azure/arm-compute [View full logs]  [Preview SDK Changes]
    info	[Changelog] **Features**
    info	[Changelog]
    info	[Changelog]   - Added operation GalleryImageVersions.getLatest
    info	[Changelog]   - Added Interface GalleryImageVersionsGetLatestOptionalParams
    info	[Changelog]   - Added Interface LatestVersion
    info	[Changelog]   - Added Type Alias FileFormat
    info	[Changelog]   - Added Type Alias GalleryImageVersionsGetLatestResponse
    info	[Changelog]   - Interface GrantAccessData has a new optional parameter fileFormat
    info	[Changelog]   - Added Enum KnownFileFormat
️️✔️ azure-sdk-for-go succeeded [Detail] [Expand]
  • ️✔️Succeeded [Logs] Generate from 44947c7. SDK Automation 14.0.0
    command	sh ./eng/scripts/automation_init.sh ../../../../../azure-sdk-for-go_tmp/initInput.json ../../../../../azure-sdk-for-go_tmp/initOutput.json
    command	generator automation-v2 ../../../../../azure-sdk-for-go_tmp/generateInput.json ../../../../../azure-sdk-for-go_tmp/generateOutput.json
  • ️✔️sdk/resourcemanager/compute/armcompute [View full logs]  [Preview SDK Changes]
    info	[Changelog] ### Features Added
    info	[Changelog]
    info	[Changelog] - New enum type `FileFormat` with values `FileFormatVHD`, `FileFormatVHDX`
    info	[Changelog] - New function `*GalleryImageVersionsClient.GetLatest(context.Context, string, string, string, *GalleryImageVersionsClientGetLatestOptions) (GalleryImageVersionsClientGetLatestResponse, error)`
    info	[Changelog] - New struct `LatestVersion`
    info	[Changelog] - New field `FileFormat` in struct `GrantAccessData`
    info	[Changelog]
    info	[Changelog] Total 0 breaking change(s), 7 additive change(s).
️⚠️ azure-resource-manager-schemas warning [Detail]
  • ⚠️Warning [Logs] Generate from 44947c7. Schema Automation 14.0.0
    command	.sdkauto/initScript.sh ../azure-resource-manager-schemas_tmp/initInput.json ../azure-resource-manager-schemas_tmp/initOutput.json
    cmderr	[initScript.sh] WARN old lockfile
    cmderr	[initScript.sh] npm WARN old lockfile The package-lock.json file was created with an old version of npm,
    cmderr	[initScript.sh] npm WARN old lockfile so supplemental metadata must be fetched from the registry.
    cmderr	[initScript.sh] npm WARN old lockfile
    cmderr	[initScript.sh] npm WARN old lockfile This is a one-time fix-up, please be patient...
    cmderr	[initScript.sh] npm WARN old lockfile
    warn	File azure-resource-manager-schemas_tmp/initOutput.json not found to read
    command	.sdkauto/generateScript.sh ../azure-resource-manager-schemas_tmp/generateInput.json ../azure-resource-manager-schemas_tmp/generateOutput.json
  • ️✔️compute [View full logs]  [Preview Schema Changes]
️❌ azure-powershell failed [Detail]
  • Pipeline Framework Failed [Logs] Generate from 44947c7. SDK Automation 14.0.0
    command	sh ./tools/SwaggerCI/init.sh ../azure-powershell_tmp/initInput.json ../azure-powershell_tmp/initOutput.json
    command	pwsh ./tools/SwaggerCI/psci.ps1 ../azure-powershell_tmp/generateInput.json ../azure-powershell_tmp/generateOutput.json
    SSL error: syscall failure: Broken pipe
    Error: SSL error: syscall failure: Broken pipe
  • Az.compute.DefaultTag [View full logs
    error	Fatal error: SSL error: syscall failure: Broken pipe
    error	The following packages are still pending:
    error		Az.compute.DefaultTag
Posted by Swagger Pipeline | How to fix these errors?

@openapi-pipeline-app
Copy link

openapi-pipeline-app bot commented Jul 3, 2023

Generated ApiView

Language Package Name ApiView Link
Swagger Microsoft.Compute https://apiview.dev/Assemblies/Review/c367bf26c0ef4508a8a3a07fa384c652
Go sdk/resourcemanager/compute/armcompute https://apiview.dev/Assemblies/Review/e3ca2efa7a864b5bbb58ce485d33e19c
Java azure-resourcemanager-compute-generated https://apiview.dev/Assemblies/Review/9f7b2295e0e740fb92583070d840e744
.Net Azure.ResourceManager.Compute https://apiview.dev/Assemblies/Review/8c69bd4a2f4446229fcc30b33d386b13
JavaScript @azure/arm-compute https://apiview.dev/Assemblies/Review/b2395da659be43a1b409d664eaaa14de

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.

2 participants