skip to Main Content

Following error i am getting when try to create Virtual environment in VS Code

PS C:UsersdellDocumentsProgramming> python -m venv C:UsersdellDocumentsProgrammingvenv
spelling of the name, or if a path was included, verify that the path is correct and try again.
At line:1 char:1
python -m venv C:UsersdellDocumentsProgrammingvenv

CategoryInfo : ObjectNotFound: (python:String) [], CommandNotFoundException
FullyQualifiedErrorId : CommandNotFoundException

PS C:UsersdellDocumentsProgramming> python3 -m venv C:UsersdellDocumentsProgrammingvenv
e App Execution Aliases.
PS C:UsersdellDocumentsProgramming> python3 -m venv C:UsersdellDocumentsProgrammingvenv
python3 : The term ‘python3’ is not recognized as the name of a cmdlet, function, script file, or operable program. Check the
spelling of the name, or if a path was included, verify that the path is correct and try again.
At line:1 char:1
python3 -m venv C:UsersdellDocumentsProgrammingvenv

CategoryInfo : ObjectNotFound: (python3:String) [], CommandNotFoundException
FullyQualifiedErrorId : CommandNotFoundException

PS C:UsersdellDocumentsProgramming> python3 -m venv C:UsersdellDocumentsProgrammingvenv
Python was not found; run without arguments to install from the Microsoft Store, or disable this shortcut from Settings > Managge App Execution Aliases.

I have turned off python & python 3 on App Execution Aliases as well but it doesnt work

2

Answers


  1. Sorry this isn’t an answer but does python work in other env’s (sublime text, python IDLE etc). Also if it doesn’t try running the commands in admin mode in powershell or use the built in vs code terminal.

    Login or Signup to reply.
  2. Judging by the error message, there may be an error with your command, which requires more information to solve the problem.

    Another option is to create a virtual environment using the command palette.

    Ctrl+Shift+P –> Python: Create Environment

    enter image description here

    Then choose according to your needs.

    https://code.visualstudio.com/docs/python/environments#_using-the-create-environment-command

    Login or Signup to reply.
Please signup or login to give your own answer.
Back To Top
Search