False positive Breaking Change for additionalProperties
- Dominant language
- C#
- Stars
- 135
- Forks
- 260
- Avg merge
- 1d 22h
- Merged PRs (30d)
- 115
Description
The false positive is reported here:
https://github.com/Azure/azure-rest-api-specs/pull/28023/checks?check_run_id=22174134297
The new API uses that [standard TypeSpec definition](https://github.com/Azure/typespec-azure/blob/25d706e772e230bce79f89618625cbf206e1f45a/packages/typespec-azure-resource-manager/lib/arm.foundations.tsp#L297-L306)
``` tsp
/**
* Standard type definition for Azure Resource Manager Tags property.
*
* It is included in the TrackedResource template definition.
*/
@doc("The Azure Resource Manager Resource tags.")
model ArmTagsProperty {
@doc("Resource tags.")
tags?: Record;
}
```
It generates this Swagger:
``` json
"tags": {
"type": "object",
"description": "Resource tags.",
"additionalProperties": {
"type": "string"
}
},
```
The old API has `tags` properties that reference a `
``` json
"tags": {
"description": "Resource tags",
"$ref": "#/definitions/ResourceTags"
},
```
``` json
"ResourceTags": {
"description": "Resource tags",
"type": "object",
"additionalProperties": {
"type": "string"
},
"x-ms-mutability": [
"read",
"create",
"update"
]
},
```
The SDKs do not generated `ResourceTags` model.
Contributor guide
Assessment
This issue has not been assessed yet.