0

Over the last few months I have installed python several times and used it from both PowerShell and from within VSCode. I notice that sometimes pip install <package> works and sometimes python pip -m install <package> works, and that sometimes one works and the other doesn't.

Can someone explain why the behaviour is different, and what I have to do so I can always use pip install <package>? Note I often use virtual environments as well.

Mark Kortink
  • 1,770
  • 4
  • 21
  • 36
  • hard to say without looking at a particular case. When it does not work what does the error message(if any) say ? Maybe you need to add pip to path. – Harsha Limaye Nov 05 '20 at 20:40
  • 2
    Does this answer your question? [What's the difference between "pip install" and "python -m pip install"?](https://stackoverflow.com/questions/25749621/whats-the-difference-between-pip-install-and-python-m-pip-install) Please at least do a search before asking on Stack Overflow. [Asking on Stack Overflow is not a substitute for doing your own research.](//meta.stackoverflow.com/a/261593/843953), especially when another question exists with a nearly identical title – Pranav Hosangadi Nov 05 '20 at 20:42
  • @Pranav Hosangadi - I did do a search, I love StackExchange but its search kind of over reaches. Thanks. – Mark Kortink Nov 05 '20 at 21:31
  • @Harsha Limaye - Fatal error in launcher: Unable to create process using '"c:\users\mark\appdata\local\programs\python\python38\python.exe" "C:\Users\mark\AppData\Local\Programs\Python\Python38\Scripts\pip.exe" ': The system cannot find the file specified. – Mark Kortink Nov 05 '20 at 21:32
  • @Harsha Limaye - Weird, it is looking in a python 3.8 directory, I uninstalled 3.8 in an attempt to force VSCode to use the right interpreter for the terminal window. – Mark Kortink Nov 05 '20 at 21:34

0 Answers0