Azure / Azure/bicep

vs-bicep sanity testing: The warning doesn't disappear and an additional error message appears in the Error List after selecting "Remove unnecessary string interpolation" option

Open
#14,981 1 comment 0 reactions 0 assignees View on GitHub
devdiv VisualStudio
Dominant language
Bicep
Stars
3.6k
Forks
830
Avg merge
1d 21m
Merged PRs (30d)
79

Description

**OS Version/SKU:** Win10 22H2/Enterprise
**VS Version/SKU:** 17.12.0 Preview 3.0 [35303.189.main]
**Bicep Build:** [14970](https://github.com/Azure/bicep/actions/runs/10689134885)

**Repro Steps:**

1. Start with this main.bicep file:
```
var name = 'name'
resource a 'Astronomer.Astro/organizations@2023-08-01' = {
name: '${name}'
location: 'westus'
}
```
2. Check there is a warning in the Error List.
![image](https://github.com/user-attachments/assets/5756d929-65e6-4638-8c1a-7b45fa748cdd)
3. Click on the line with the warning and click the light bulb -> Select "Remove unnecessary string interpolation".
4. Check whether the warning has disappeared in the Error List.

**Expect:**
The warning should disappear in the Error List.

**Actual:**
The warning doesn't disappear and an additional error message appears in the Error List.
![image](https://github.com/user-attachments/assets/8235017c-27cc-4011-97d6-7330b4dcbe1b)

Contributor guide

Open the contributing guide

Research direction

Reproduce the issue in Visual Studio 17.12 Preview using the main.bicep example and the listed light-bulb action. Check the Error List before and after selecting "Remove unnecessary string interpolation"; done means the warning disappears without an additional error.

Written by the indexing model from the issue text.

Assessment

Tech stack
azure
Domain
tooling
Issue type
Bug
Difficulty
3/5
Estimated time
1-2 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
35/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.