Using the template expression variable syntax for a job-scoped variable is resulting in it being resolved to empty string. It seems that the compiler is not able to find a replacement value:
Template variables silently coalesce to empty strings when a replacement value isn't found.
Is this expected behavior? I could not find any mention of this in the documentation. Code example:
# Global variables are correctly replaced
variables:
globalVar1: hello
extends:
template: template.yml
stages:
- stage: stage1
jobs:
- job: job1
variables:
localVar1: world
steps:
- task: DisplayString
inputs:
stringToDisplay: ${{ variables.globalVar1}} ${{ variables.localVar1}}
# This shows "hello "
Furthermore I have not been able to use the ${{ var }} syntax with variable templates either.
Using the template expression variable syntax for a job-scoped variable is resulting in it being resolved to empty string. It seems that the compiler is not able to find a replacement value:
Is this expected behavior? I could not find any mention of this in the documentation. Code example:
Furthermore I have not been able to use the
${{ var }}syntax with variable templates either.