Azure / Azure/azure-openapi-validator

False positive for parent segments in path?

Open
#720 0 comments 0 reactions 0 assignees View on GitHub
Dominant language
TypeScript
Stars
53
Forks
57
Avg merge
1d 23h
Merged PRs (30d)
2

Description

**Describe the bug**

We get LintDiff warnings like this.

⚠️ MissingSegmentsInNestedResourceListOperation | A nested resource type's List operation must include all the parent segments in its api path.Location: Microsoft.Network/preview/2024-01-01-preview/ipAddressManager.json#L8 | RPC-Get-V1-11

But its unclear why.

The path its complaining about seems to be
"/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Network/networkManagers/{networkManagerName}/verifierWorkspaces/{workspaceName}/reachabilityAnalysisIntents": {

it looks like the parent path declaration is compatible:
"/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Network/networkManagers/{networkManagerName}/verifierWorkspaces/{workspaceName}": {

source file:
https://github.com/Azure/azure-rest-api-specs-pr/blob/bdafd95bd0cd77f68be044bd5e8436518c9f5920/specification/network/resource-manager/Microsoft.Network/preview/2024-01-01-preview/networkVerifier.json#

Is the analyzer confused by the extra query parameters?

**To Reproduce**
Steps to reproduce the behavior:
See
https://github.com/Azure/azure-rest-api-specs-pr/pull/17956/checks?check_run_id=26909351197

**Expected behavior**
If its a real false positive, no warning, right.

**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]

**Additional context**

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.