Install pip the official way:
curl https://bootstrap.pypa.io/get-pip.py -o get-pip.py
python3.8 get-pip.py
made 3.8 my default Python version
It depends on how you did that, but it might break something in your OS. For example some packages on Ubuntu 18.04 might depend on python being python2.7 or python3 being python3.6 with some pip packages preinstalled.
Install pip the official way:
curl https://bootstrap.pypa.io/get-pip.py -o get-pip.py
python3.8 get-pip.py
made 3.8 my default Python version
It depends on how you did that, but it might break something in your OS. For example some packages on Ubuntu 18.04 might depend on python being python2.7 or python3 being python3.6 with some pip packages preinstalled.
Install pip the official way:
curl https://bootstrap.pypa.io/get-pip.py -o get-pip.py
python3.8 get-pip.py
made 3.8 my default Python version
It depends on how you did that, but it might break something in your OS. For example some packages on Ubuntu 18.04 might depend on python being python2.7 or python3 being python3.6 with some pip packages preinstalled.
sudo apt install python3.8
sudo apt install python3.8-distutils
wget https://bootstrap.pypa.io/get-pip.py
sudo python3.8 get-pip.py
installing pip for 3.8 using get-pip.py on 18.04 leaves a broken state
I installed python 3.10 on my Mac but when I enter “python —version” it returns 3.8.3. How do I fix this?
Installing win32api in python
Install SQLite3 on Python 3
That error means that you didn't have the SQLite development package installed when you built Python. The sqlite3 binary CLI program is totally irrelevant; Python does not use that, and its presence does not mean you have the correct package installed. The necessary package is libsqlite3-dev. You don't need --enable-loadable-sqlite-extensions.
Videos
In order to make sure you are using the correct pip, please use it as follows:
python3.8 -m pip install pyinotify
Brett Cannon, one of the Python core developers, just recently published a blog article about this topic: https://snarky.ca/why-you-should-use-python-m-pip/
This all said, you usually want to install Python packages into a virtual environment, not in the system Python.
https://realpython.com/python-virtual-environments-a-primer/
sudo apt install python3-pip or python3.8-pip .
Let the system manage your Python version.
Edit:
The original question was trying to install pip via python -m pip, and after the original poster used apt, the system package manager, instead, they were able to get pip working correctly.
As noted in the comments and in jugmac00's answer, it is now recommended to use pip by calling as a Python module:
python -m pip install pyinotify
If multiple versions of Python are installed on the system and this isn't the default version, you may need to specify the version:
python3.8 -m pip install pyinotify
» pip install pip