Python Forum
installing third-party modules
Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
installing third-party modules
#1
What I'm using:
Windows 10
Python 3.8 32-bit

Complete and utter Python Noob here, with zero coding experience. Hello! I'm following along with the "Automate The Boring Stuff" tutorial (which seems well-known) on YouTube. Things were fine until we got to installing third-party modules...I've come to a screeching halt.

Tutorial says to first install the module "pyperclip" using pip. I am told to type the following in the command prompt:

 pip install pyperclip 
when I do that, command prompt returns the following:

'pip' is not recognized as an internal or external command, operable program or batch file.
I've tried searching for a solution, including on threads here, but solutions vary and are often beyond my current level of comprehension, and/or don't quite address the issue I'm having. It's really frustrating. The two camps seem to be either A.) you ACTUALLY need to type a ton of other stuff in the command prompt that was left out of the tutorial for no apparent reason (and what you're supposed to type seems to change depending on the source), or B.)you need to uninstall and reinstall Python and hit a checkbox or two to ensure pip is where you need it (although I believe Python's website says pip is automatically included, so why would they make it difficult to access??).

Does someone have an explanation of why I am getting the response I'm getting in the command prompt?

Thanks.


Here's a link to automate the boring stuff index on importing 3rd party modules: http://automatetheboringstuff.com/appendixa/
Reply
#2
Try to avoid installing via pip outside the virtual environment.
python -m venv <you_venv_name>
# then activate your venv
<your_venv_name>\Scripts\activate.bat
# now you can use pip safely
pip install <name>
Reply
#3
try pip3
and, just in case, you are using pip from command line, correct?
Reply
#4
Look at Python 3.8 (3.6-3.7) and pip installation under Windows.
shabux Wrote:'pip' is not recognized as an internal or external command, operable program or batch file.
In link over look at Fixing Path if needed,this is when have installed and get a message like this.
Reply
#5
(Apr-07-2020, 09:04 AM)Mateusz Wrote: Try to avoid installing via pip outside the virtual environment.
python -m venv <you_venv_name>
# then activate your venv
<your_venv_name>\Scripts\activate.bat
# now you can use pip safely
pip install <name>

Virtual environment = IDLE, or a python file?

By "avoid" are you implying that installing via pip outside the virtual environment is bad? Either way, I'd rather follow along with what the tutorial is doing, unless there's a convincing argument for doing otherwise.

I don't know what your using in your example, or what you're typing, as I am a noob per my post.

(Apr-07-2020, 10:31 AM)snippsat Wrote: Look at Python 3.8 (3.6-3.7) and pip installation under Windows.
shabux Wrote:'pip' is not recognized as an internal or external command, operable program or batch file.
In link over look at Fixing Path if needed,this is when have installed and get a message like this.

I uninstalled and re-installed Python, using the link you provided, and was able to successfully install pyperclip in the command prompt! Thanks!!

I got a warning that I am "using pip version 19.2.3, however version 20.0.2 is available." It says I can "upgrade via the 'python -m install --upgrade pip' command". So, should I just type the following into the command prompt:

python -m install --upgrade pip
Thanks for your help.

(Apr-12-2020, 08:13 PM)shabux Wrote:
(Apr-07-2020, 09:04 AM)Mateusz Wrote: Try to avoid installing via pip outside the virtual environment.
python -m venv <you_venv_name>
# then activate your venv
<your_venv_name>\Scripts\activate.bat
# now you can use pip safely
pip install <name>

Virtual environment = IDLE, or a python file?

By "avoid" are you implying that installing via pip outside the virtual environment is bad? Either way, I'd rather follow along with what the tutorial is doing, unless there's a convincing argument for doing otherwise.

I don't know what your using in your example, or what you're typing, as I am a noob per my post.

(Apr-07-2020, 10:31 AM)snippsat Wrote: Look at Python 3.8 (3.6-3.7) and pip installation under Windows.
In link over look at Fixing Path if needed,this is when have installed and get a message like this.

I uninstalled and re-installed Python, using the link you provided, and was able to successfully install pyperclip in the command prompt! Thanks!!

I got a warning that I am "using pip version 19.2.3, however version 20.0.2 is available." It says I can "upgrade via the 'python -m install --upgrade pip' command". So, should I just type the following into the command prompt:

python -m install --upgrade pip
Thanks for your help.

I just went ahead and upgraded in the cdm and it worked. Last question on this thread: Do I need to re-install the pyperclip module now in the cdm (since I upgraded pip), or do I not have to re-install the pyperclip module?
Reply
#6
Quote:p module now in the cdm (since I upgraded pip), or do I not have to re-install the pyperclip module?
It never hurts to try. Pip will not re-install if module is up to date.
Reply


Possibly Related Threads…
Thread Author Replies Views Last Post
  Running 3rd party libs on Steam Deck (Arch Linux) with restricted access metulburr 0 1,874 Jan-07-2023, 10:41 PM
Last Post: metulburr
  Installing Modules PythonBorg 10 2,067 Sep-03-2022, 09:58 AM
Last Post: PythonBorg
Question Trouble installing modules/libraries and getting Notepad++ to show cyrillic letters Dragiev 6 2,272 Jul-24-2022, 12:55 PM
Last Post: Dragiev
  Avoid third party functions to wrote my python code into system debug-log? mark 9 2,219 Apr-09-2022, 08:41 PM
Last Post: mark
  How to use a function from third party library? rrowhe4d 2 1,871 Aug-31-2021, 04:30 PM
Last Post: Larz60+
  Installing Modules / packages Oshadha 1 1,707 Feb-05-2021, 08:04 PM
Last Post: Jeff900
  Did interpreter 'compile' all import modules(from thrid-party) jamesyuan 10 4,335 Oct-19-2020, 10:49 AM
Last Post: jamesyuan
  How to detect third party packages used in the code SriRajesh 5 2,988 Sep-21-2019, 05:59 AM
Last Post: ndc85430
  3rd Party Modules - Installing martyl 9 5,720 Jun-15-2018, 01:49 AM
Last Post: martyl
  pip and installing modules deep_logic 2 6,085 Jun-25-2017, 03:23 AM
Last Post: deep_logic

Forum Jump:

User Panel Messages

Announcements
Announcement #1 8/1/2020
Announcement #2 8/2/2020
Announcement #3 8/6/2020