Facing an issue while trying to run the AzurePowerShell@5 task in Azure devops
Az version null not avaiable locally on the agent. Downloading dynamically.
Validate-VersionParameters: Cannot convert value 'null' to type 'System.Version'
Exception: /home/vsts/work/_tasks/AzurePowerShell_72a1931b-effb-4d2e-8fd8-f8472a07cb62/5.218.0/Utility.ps1:94
Line |
94 | … throw ("Could not find the module path with given version …
| ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
| Could not find the module path with given version.
[![enter image description here][1]][1]
This task requires a parameter azurePowerShellVersion. Provide the value 'Latest' or 'Other'.
There was a github issue raised for this issue. https://github.com/MicrosoftDocs/azure-devops-docs/issues/11928 .
The highlighted parameter is required. https://learn.microsoft.com/en-us/azure/devops/pipelines/tasks/reference/azure-powershell-v5?view=azure-pipelines