Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

"ENOENT: no such file 'template.json'" when using 'parameters.json' with 'template.bicep' #1574

Open
AlanMcBee opened this issue Apr 3, 2023 · 2 comments
Labels

Comments

@AlanMcBee
Copy link

Does this occur consistently? Yes
Repro steps:
Use both the ARM VSCode extension and the Bicep VSCode extension

  1. Create or open a Bicep file. If created from an ARM template.json file, remove the template.json file, so that only the template.bicep file exists.
  2. Create or open the corresponding ARM template.parameters.json parameters file
  3. Navigate around in VSCode in the parameters file for a while, including switching away from the window to another window

Expected: no error
Actual: toast notification: ENOENT: no such file or directory, open 'c:...\template.json'

I am using only Bicep. Although I could keep a compiled template.json file just to prevent the error or check the linkage between template and parameters using the VSCode extensions, this seems sub-efficient.


Action: Go To Definition
Error type: ENOENT
Error Message: ENOENT: no such file or directory, open 'c:...\non-existent-arm-template.json'

Version: 0.15.10
OS: win32
OS Release: 10.0.22624
Product: Visual Studio Code
Product Version: 1.77.0
Language: en

@pamelafox
Copy link
Member

I experience as well, for a main.parameters.json without a main.json.

@MarcoJanse
Copy link

I experience the same:

Does this occur consistently? Yes
Repro steps:

  1. Compare two .arm JSON-files using the Select for Compare and Compare with Selected
  2. Select block of code from left side to copy to the right side

Action: Go To Definition
Error type: ENOENT
Error Message: ENOENT: no such file or directory, open <pathToFile>\azure-monitor-baseline-alerts\patterns\alz\alzarm.custom.json

Version: 0.15.12
OS: win32
OS Release: 10.0.26100
Product: Visual Studio Code
Product Version: 1.94.2
Language: en

Screenshot

Image

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

3 participants