top of page

Recent Posts

Archive

Tags

Cannot Retrieve Dynamic Parameters for the Cmdlet Cannot find path '.json' because it does not exist

Hello! I ran into an issue when deploying Bicep file with PowerShell. The error for which the title of this article is named absolutely baffled me. This was further exacerbated by my need to do some testing on an issue that I spent a lot of time debugging. What I learned from solving this error is that sometimes we get so frustrated on Fridays at 3PM that we forget the basics.



What could that obscure filepath be? I went to that location and it seems like a temp location on my MacBook with files that I know from experience that I likely should not touch. Why would PowerShell or Bicep be looking there anyway? Also, since I am working with Bicep files, why are the powers that be looking for a JSON file in the first place. I cannot answer the first question but as to the second, Bicep code transpiles to ARM so looking for the JSON file makes sense.


Now to the solution. There is a command for Bicep 'bicep build' that works well for debugging pre-deployment errors. If we look amongst the sea of yellow warnings, we will find a few errors in red:



This is finally the information that I am looking for. In my main Bicep file, I had somehow overlooked some parameters that were not defined whatsoever:



This was not a piece that I worked with and I did not want to test that piece anyway, so I commented it out and voila! Now on to debugging my code changes....

Comments


Single post: Blog_Single_Post_Widget
bottom of page