Azure / Azure/autorest

[openapi-to-typespec] Missing `@typespec/versioning` import

Open
#4,931 3 comments 0 reactions 1 assignee Claimed by @pshao25 View on GitHub
needs-team-attention openapi-to-tsp
Dominant language
TypeSpec
Stars
4.8k
Forks
736
Avg merge
2d 14h
Merged PRs (30d)
1

Description

When converting a swagger to typespec, the `@versioned` decorator is correctly added, but the spec is missing the import and using statements. We need to add the following in the main.tsp ouput:

```
import "@typespec/versioning";

using TypeSpec.Versioning;
```

Showed up when converting the following spec: https://github.com/Azure/azure-rest-api-specs/blob/main/specification/appconfiguration/data-plane/readme.md

cc @joheredi @tadelesh

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.