Azure / azure-sdk-tools

Tools repository leveraged by the Azure SDK team.
MIT License
113 stars 177 forks source link

If a new spec is not added to README, LintDiff won't validate it (related to Avocado). #7761

Open konrad-jamrozik opened 8 months ago

konrad-jamrozik commented 8 months ago

Example:

It did not run on diagnostic.json

In theory such scenario should be caught by Swagger Avocado (as can be seen here), but we had to make it a non-blocking check.

For context, see this Teams discussion.

This issue is very related to:

Relevant doc:

konrad-jamrozik commented 8 months ago

We are considering making LintDiff fail if it detects a spec file was added that is not in any README file. This LintDiff log has an example of this. We can see following log snippet:

RETURN definition CommonPRContext.getReadmeDiffs.changedFiles: {
    "additions": ["specification/compute/resource-manager/Microsoft.Compute/DiagnosticRP/preview/2024-03-01-preview/diagnostic.json"],

where that diagnostic.json file does not show up in any README. We could modify CommonPRContext.getReadmeDiffs to report such cases and process them downstream.