LintDiff did not catch anonymous model in ARM swagger

Open
#573 0 comments 2 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Assessment

Difficulty
4/5
Estimated time
3-5 days
Newbie friendliness
42/100
Issue type
Bug
Clarity
Mostly clear
Activity status
Stale
Tech stack
openapi, typescript
Domain
api, tooling

Research direction

Start by running LintDiff against specification/azurestackhci/resource-manager/Microsoft.AzureStackHCI/preview/2023-07-01-preview/virtualNetworks.json at the referenced revision and compare its result with the anonymous model at lines 421-446. Trace the anonymous-model validation rule and the CI run details, then add coverage showing that this input fails with the expected error.

Written by the indexing model from the issue text.

Description

Describe the bug
PR https://github.com/Azure/azure-rest-api-specs/pull/24998 contains Swagger with anonymous model

There should be a rule to catch that https://github.com/Azure/azure-rest-api-specs/pull/24998, but it seems not work in above case.

CI run: https://dev.azure.com/azure-sdk/internal/_build/results?buildId=2998970&view=logs&j=0574a2a6-2d0a-5ec6-40e4-4c6e2f70bea2&t=80c3e782-49f0-5d1c-70dd-cbee57bdd0c7

To Reproduce
Steps to reproduce the behavior:
Run LintDiff on https://github.com/Azure/azure-rest-api-specs/blob/52f765effde90f870a7edfd708d97918dbda82c6/specification/azurestackhci/resource-manager/Microsoft.AzureStackHCI/preview/2023-07-01-preview/virtualNetworks.json

Expected behavior
LintDiff fail with error on anonymous model.

Screenshots
If applicable, add screenshots to help explain your problem.

Desktop (please complete the following information):

  • OS: [e.g. iOS]
  • Browser [e.g. chrome, safari]
  • Version [e.g. 22] UnifiedPipeline 0.218.0

Additional context
Add any other context about the problem here.

Dominant language
TypeScript
Stars
53
Forks
57
Avg merge
1d 23h
Merged PRs (30d)
2

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

More from Azure/azure-openapi-validator

All issues in Azure/azure-openapi-validator

Similar issues

More TypeScript issues

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.