Force restore doesn't clear previous errors
- Dominant language
- Bicep
- Stars
- 3.6k
- Forks
- 830
- Avg merge
- 1d 21m
- Merged PRs (30d)
- 79
Description
Not sure this ever worked, I went back several months and it repros.
1) clear your cache (delete folder /.bicep/br/mcr.microsoft.com/)
2) disconnect from network
3) create a bicep file and save it with this code:
```
module m 'br/public:ai/bing-resource:1.0.1' = {
name: 'm'
}
```
4) Wait until hovering over it shows it failed with a network failure
5) restore network
6) right-click -> Restore Bicep Modules (Force)
7) it fails:
6:13:49 PM: Force restoring modules in /Users//Downloads/Untitled-2.bicep...
6:13:52 PM: Restore (force) summary:
* br:mcr.microsoft.com/bicep/ai/bing-resource:1.0.1: Failed
8) Check your cache - you'll see that the module was actually restored, but the previous failure is not getting cleared
Contributor guide
Research direction
Reproduce the failure using the cache path and the numbered offline/online steps, then start from the Restore Bicep Modules (Force) flow and its restore summary. Done means that after the module is restored, the prior network failure is cleared and the force-restore summary no longer reports the module as failed.
Written by the indexing model from the issue text.
Assessment
- Domain
- tooling
- Issue type
- Bug
- Difficulty
- 3/5
- Estimated time
- 1-2 days
- Activity status
- Stale
- Clarity
- Clearly specified
- Newbie friendliness
- 35/100