Bicep resource schema doesn't match documentation (or its own example)
- Dominant language
- TypeScript
- Stars
- 108
- Forks
- 44
- Avg merge
- 18h 53m
- Merged PRs (30d)
- 29
Description
**Bicep version**
Bicep CLI version 0.29.47 (132ade51bc)
**Describe the bug**
I'm typing out a Bicep file in Visual Studio Code and the schema it's using for a resource doesn't match the ARM documentation. Looking at the property for an [Azure Container App](https://learn.microsoft.com/en-us/azure/templates/microsoft.app/containerapps?pivots=deployment-language-bicep): `properties.template.containers[].resources.cpu`, the field expects a JSON object providing a decimal value (e.g. 0.25) as a string.
Rather, in VS Code, it's indicating this should be an integer even though the example it gives isn't even an integer.

**To Reproduce**
Hammer out a brief resource definition in a Bicep file. Here's one to get you started that demonstrates the issue:
```bicep
resource MyContainerApp 'Microsoft.App/containerApps@2024-03-01' = {
name: 'MyApp'
location: resourceGroup().location
properties: {
template: {
containers: [
{
resources: {
cpu: 0.25
}
}
]
}
}
}
```
**Additional context**
I think that about covers it.
Contributor guide
No contributing guide indexed for this repository
Research direction
Start with the provided Bicep resource definition and inspect the schema for Microsoft.App/containerApps@2024-03-01, focusing on properties.template.containers[].resources.cpu. Compare its expected type with the linked ARM documentation and the example value 0.25; done means the schema accepts the documented decimal value consistently in VS Code.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- azure, vscode
- Domain
- cloud, tooling
- Issue type
- Bug
- Difficulty
- 3/5
- Estimated time
- 1-2 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 45/100