trouble creating python3 -m venv py_envv using windows subsystem linux (using ubantu distribution)

Its my first post in askUbuntu, please bare with my discription.

command at PWD : python3 -m venv py_envv
after excuting I got an error below


The virtual environment was not created successfully because ensurepip is not
available. On Debian/Ubuntu systems, you need to install the python3-venv
package using the following command.

apt install python3.10-venv

You may need to use sudo with that command. After installing the python3-venv
package, recreate your virtual environment.

Failing command: [‘/mnt/<>/<>////AirflowBasics/py_envv/bin/python3’, ‘-Im’, ‘ensurepip’, ‘–upgrade’, ‘–default-pip’]

can anyone able to resolve this issue , please let me know if you want more context reagrding my environment or other things.
Thanks.

Asked By: JakeCaspian

||

In Ubuntu 22.04-22.10 open the terminal and type:

sudo apt install python3.10-venv
python3 -m venv py_env1

The python3 -m venv py_env1 command will create a directory called "py_env1" in your home directory, containing everything you need to install any Python package.

To use the new Python virtual environment run the following commands:

cd py_env1
source ./bin/activate
Answered By: karel