question

ZaidAbuHijleh-2604 avatar image
0 Votes"
ZaidAbuHijleh-2604 asked vipullag-MSFT edited

Python not working in Azure pipeline build VM

Im trying to run a python script in an Azure pipeline, but it doesnt seem to be working. It keeps telling me

'python' is not recognized as an internal or external command, operable program or batch file.

I have installed python and added it to the path, when I type python in the command line on the VM it works:

205193-image.png


But when I try to run the following command line task in the pipeline, it fails:

 - task: CmdLine@2
   inputs:
     script: 'python ./tools/setPythonClientVersion.py $(Build.BuildNumber)'
   displayName: Set Client Version


I get the following error:

205194-image.png

Any idea as to why this is happening and what I should do to fix it?

not-supported
image.png (46.8 KiB)
image.png (18.1 KiB)
5 |1600 characters needed characters left characters exceeded

Up to 10 attachments (including images) can be used with a maximum of 3.0 MiB each and 30.0 MiB total.

1 Answer

vipullag-MSFT avatar image
0 Votes"
vipullag-MSFT answered

@ZaidAbuHijleh-2604

Welcome to Microsoft Q&A Platform, thanks for posting your query here.

Azure DevOps related queries/issues are currently not supported on this Microsoft Q&A platform. Please check this supported products list here (more to be added later on).

I would request you to please post your queries in dedicated forums as in below links:
https://developercommunity.visualstudio.com/spaces/21/index.html
https://developercommunity.visualstudio.com/t/get-unique-id-from-devops-organization/756710
https://stackoverflow.com/questions/tagged/azure-devops


Hope that helps.
Please 'Accept as answer' if it helped, so that it can help others in the community looking for help on similar topics.


5 |1600 characters needed characters left characters exceeded

Up to 10 attachments (including images) can be used with a maximum of 3.0 MiB each and 30.0 MiB total.