-
Notifications
You must be signed in to change notification settings - Fork 730
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
Building bicep parameterfiles with compile-time imported UDFs, exception is thrown #12911
Comments
UDFs aren't supported in bicepparam files at the moment. While the compiler blocks function and type imports via the cherry-pick syntax ( We could add a linter to check the use of wildcard import properties and raise a diagnostic when a function is dereferenced. This would at least provide an opportunity to surface a more helpful error message than the |
Closes #12911 ###### Microsoft Reviewers: [Open in CodeFlow](https://microsoft.github.io/open-pr/?codeflow=https://github.com/Azure/bicep/pull/13459)
Bicep version
Bicep CLI version 0.24.24 (5646341)
Describe the bug
When building a bicep parameter file that is referring a compile-time imported UDF, the following compilation error is thrown:
Failed to evaluate parameter "paramname": The template function '_1.getValue' is not expected at this location.
To Reproduce
I've included a project as attachment to reproduce the situation.
build.ps1 --> main.bicepparam.bicep --> throws the error
Additional context
See attachment:
bicep-udt-compiletimeimport-bicepparam-notexpected.zip
The text was updated successfully, but these errors were encountered: