"msg": "No package matching 'python' is available"

Hello,

I tried installing python dependencies on ubuntu using ansible. However, I got this error
fatal: [18.157.79.199]: FAILED! => {“changed”: false, “msg”: “No package matching ‘python’ is available”}

Below is a screenshot of my play:

This is correct. There is no package called python.
Probably your Ubuntu is recent and the package you want is python3.
Same for the related packages.

(attachments)

Thank you for this
I just tried with Ubuntu 18 and also python3 packages.
Here is the error I have:

fatal: [3.121.159.145]: FAILED! => {“changed”: false, “msg”: “No package matching ‘python3-pip’ is available”}

I fixed it by adding update_cache parameter to update the repo first before installing my packages

Thank you for the tips