New Azure subscription variable bug

Started trying to use the new Azure subscription variable type. I have a variable called AzureSubscription and it’s scoped to two different subscriptions based on environment. In my deployment process I have a template based on the Azure powershell step. In the parameter list I created a variable of type “Azure Subscription” and I use that in the subscription input on the step template. On the project I also set a variable up for my environment specific subscription values and use that in the parameter input on the step template. This results in the error you see in the screenshot. I did find that if I change the parameter type on the step template back to single text box I can still use the Azure Subscription variable on the project and that continues to work.

Hi,

Thanks for getting in touch.

It looks like you have forgotten to include your screenshot, so I followed along your setup and was able to reproduce an error. The error message was Couldn’t find an account with the Id zzz, where zzz is the name of the project account variable.
This seems like a bug as it is not consistent with how step template variables should work. I have created an issue for you to track and be notified when it has been fixed.

In the meantime, there is a workaround by putting the account field on the step in the project in to binding mode and entering the binding expression #{project variable name}.

I hope this workaround helps you out.

Regards
Ben

Ha, my bad. Glad you could repro. Thanks!