Add "placement" top-level property to fallback Az resource type - #20172
Add "placement" top-level property to fallback Az resource type#20172Anthony Martin (anthony-c-martin) with Copilot wants to merge 5 commits into
Conversation
Co-authored-by: anthony-c-martin <38542602+anthony-c-martin@users.noreply.github.com>
|
Test this change out locally with the following install scripts (Action run 31451449448) VSCode
Azure CLI
|
|
Copilot can you add a scenario test to verify a VMSS .bicep file can be authored using this functionality without generating any diangostics? |
Co-authored-by: anthony-c-martin <38542602+anthony-c-martin@users.noreply.github.com>
Added |
|
Copilot fix the tests |
Co-authored-by: anthony-c-martin <38542602+anthony-c-martin@users.noreply.github.com>
Fixed in a3fd... — two baseline diagnostics files (
Fixed in 2222181 — two baseline diagnostics files ( |
|
Copilot see latest failures |
Co-authored-by: anthony-c-martin <38542602+anthony-c-martin@users.noreply.github.com>
Fixed in 6d1ebce — the |
The fallback Azure resource type definition used for unrecognized resource types/API versions was missing the
placementtop-level property (zone placement policy), which exists on the ARM side alongsidezones,tags,location, etc.Changes
AzResourceTypeProvider.KnownTopLevelResourceProperties: added aplacementobject property mirroring the ARMPlacementtype:zonePlacementPolicy(required) — string literal union'NotSpecified' | 'Any' | 'None' | 'Auto', widened tostringas fallbackincludeZones—string[]excludeZones—string[]WriteOnlyDeployTimeConstantPropertyNames: addedplacementalongsidezones, since its value can be normalized/changed by the RP and shouldn't be safely read at deploy time.placementcases toTopLevelResourcePropertiesTestsfor both resources and modules.Example of what now compiles without a fallback warning: