versionUpgradeOption: 'string' is not working as expected.
- Dominant language
- TypeScript
- Stars
- 108
- Forks
- 44
- Avg merge
- 18h 53m
- Merged PRs (30d)
- 29
Description
### Resource Type
Microsoft.CognitiveServices/accounts/deployments
### Api Version
2023-05-01
### Issue Type
Property(s) do not have expected effect on deployment
### Other Notes
Below bicep deployment fails with error:
**[{"code":"DeploymentModelNotSupported","message":"Creating account deployment is not supported by the model 'gpt-4-32k'. This is usually because there are better models available for the similar functionality."}]** for all options of **versionUpgradeOption** ['NoAutoUpgrade', 'OnceCurrentVersionExpired', 'OnceNewDefaultVersionAvailable']
while the deployment succeeds when we specify the version explicitly as '0613'.
We encountered this error as older version '0314' got expired.
### Bicep Repro
```bicep
param cognitiveServiceName string = 'test'
param location string = 'eastus'
param modelName string = 'gpt-4-32k'
param capacityInThousandTPM int = 2
targetScope = 'resourceGroup'
var modelDeploymentName = 'md-${modelName}'
@allowed([
'S0'
])
param sku string = 'S0'
resource cognitiveService 'Microsoft.CognitiveServices/accounts@2021-10-01' = {
name: cognitiveServiceName
location: location
sku: {
name: sku
}
kind: 'OpenAI'
properties: {
apiProperties: {
statisticsEnabled: false
}
publicNetworkAccess :'Disabled'
customSubDomainName: toLower(cognitiveServiceName)
}
}
resource cognitiveServicesAccounts 'Microsoft.CognitiveServices/accounts/deployments@2023-05-01'= {
name: modelDeploymentName
parent: cognitiveService
sku : {
name : 'Standard'
capacity: capacityInThousandTPM
}
properties: {
model: {
format: 'OpenAI'
name: modelName
}
versionUpgradeOption: 'OnceNewDefaultVersionAvailable'
}
}
output modelName string = modelDeploymentName
output cognitiveServiceName string = cognitiveService.name
output congitiveServiceRI string = cognitiveService.id
```
### Confirm
- [X] I have read the troubleshooting guide and looked for duplicates.
Contributor guide
No contributing guide indexed for this repository
Research direction
Start by reproducing the Bicep deployment for Microsoft.CognitiveServices/accounts/deployments@2023-05-01 with gpt-4-32k and each versionUpgradeOption value. Compare the behavior with the explicit model version '0613' and inspect how this resource type is defined in bicep-types-az. Done means the mismatch is resolved or clearly documented for all listed options.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- azure
- Domain
- cloud
- Issue type
- Bug
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 32/100