Azure / Azure/bicep-types-az

Microsoft.CostManagement/settings do not work as expected

Open
#2,701 1 comment 0 reactions 0 assignees View on GitHub
Dominant language
TypeScript
Stars
108
Forks
44
Avg merge
18h 53m
Merged PRs (30d)
29

Description

**Bicep version**
Bicep CLI version 0.39.26

**Describe the bug**
Executing bicep code to set costs tags inheritance but deployment stops with error. But setting is enabled.

First run:

Image

Image

Error message:

Status Message: The response for resource had empty or invalid content. (Code:ResourceDeploymentFailure)

Second run (after setting is enabled via code):

Image

Error message:
DeploymentWhatIfResourceInvalidResponse - Long running operation failed with status 'Failed'. Additional Info:'The request to predict template deployment changes to scope '/subscriptions/xxx' has failed due to missing or unexpected response on request '/subscriptions/xxx/providers/Microsoft.CostManagement/settings/tagInheritance?api-version=2025-03-01'. Diagnostic information: timestamp '20260320T140157Z', tracking id '7c4ac7f2-f3b2-4998-8137-f5620ab4d81c', request correlation id 'f5e6d9e4-d9ba-4498-bd6d-0ef52182735f', location 'westeurope'.'

**To Reproduce**
Added code below to bicep file:

resource tag_inheritance 'Microsoft.CostManagement/settings@2025-03-01' = {
name: 'tagInheritance'
kind: 'taginheritance'
properties: {
preferContainerTags: false
}
}

**Additional context**
targetScope = 'subscription'
https://learn.microsoft.com/en-us/azure/templates/microsoft.costmanagement/2024-08-01/settings?pivots=deployment-language-bicep

Contributor guide

No contributing guide indexed for this repository

Research direction

Start with the Microsoft.CostManagement/settings@2025-03-01 resource declaration and compare its tagInheritance properties with the linked Azure template documentation. Reproduce the subscription deployment and what-if behavior, then verify whether the generated resource definition accepts the declaration and whether the reported API response is handled correctly.

Written by the indexing model from the issue text.

Assessment

Tech stack
azure
Domain
cloud, infrastructure
Issue type
Bug
Difficulty
3/5
Estimated time
1-2 days
Activity status
Quiet
Clarity
Mostly clear
Newbie friendliness
45/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.