Azure / Azure/azure-sdk-tools

[LintDiff] Upgrade autorest to latest

Open
#7,755 7 comments 0 reactions 1 assignee Assigned to @konrad-jamrozik View on GitHub
Central-EngSys Spec PR Tools
Dominant language
C#
Stars
135
Forks
260
Avg merge
3d 1h
Merged PRs (30d)
143

Description

LintDiff is currently using `autorest` pinned to 3.6.1:

https://dev.azure.com/devdiv/DevDiv/_git/openapi-alps?path=/private/azure-swagger-validation/azureSwaggerValidation/package.json&version=GBmain&line=36&lineEnd=37&lineStartColumn=1&lineEndColumn=1&lineStyle=plain&_a=contents

It should probably be upgraded to the latest version `3.7.1`, since `3.6.1` is two years old now. However, I'm not aware of any current issues using `3.6.1`, so maybe it's better to not touch it unless we need to?

I believe `autorest@3.6.1` should automatically use the latest version of `@autorest/core`, since by default `autorest` floats the dependency as `@autorest/core@^3.2.0`:

```
if (args["v3"] && !args["version"]) {
// --v3 without --version infers --version:^3.2.0 +
args["version"] = "^3.2.0";
}
```

https://github.com/Azure/autorest/blob/8d137ce24e1af96444766688e7cd851767d6543c/packages/apps/autorest/src/app.ts#L42

For reference:
- PROD execution of AutoRest for LitnDiff is done from [`momentOfTruth.ts`](https://dev.azure.com/devdiv/DevDiv/_git/openapi-alps?path=%2Fprivate%2Fazure-swagger-validation%2FazureSwaggerValidation%2Fsrc%2FmomentOfTruth.ts&_a=contents&version=GBmain).
- Relevant [Teams discussion](https://teams.microsoft.com/l/message/19:906c1efbbec54dc8949ac736633e6bdf@thread.skype/1708983373720?tenantId=72f988bf-86f1-41af-91ab-2d7cd011db47&groupId=3e17dcb0-4257-4a30-b843-77f47f1d4121&parentMessageId=1708550459988&teamName=Azure%20SDK&channelName=TypeSpec%20Discussion&createdTime=1708983373720).

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.