There are three ways to get the list of all the libraries or packages or modules installed in python using pip list command, pip freeze command and help function .
All the three ways of listing all the packages installed in python are explained below along with we also explained.
- Pip list all the outdated package installed in python
- pip list all the up to date package installed in python
- pip list all installed packages in json format
- pip list installed packages along with package version
1. List all the packages, modules installed in python Using pip list:
open Anaconda prompt and type the following command.
This will get the list of installed packages along with their version in angular braces which is shown below
Syntax for pip list command :
|List outdated packages
|List uptodate packages
|List editable projects.
|If in a virtualenv that has global access, do not list globally-installed packages.
|Only output packages installed in user-site.
|Restrict to the specified installation path for listing packages (can be used multiple times).
|Include pre-release and development versions. By default, pip only finds stable versions.
|Select the output format among: columns (default), freeze, or json
|List packages that are not dependencies of installed packages.
|Exclude editable package from output.
|Include editable package from output.
|Exclude specified package from the output
|Base URL of the Python Package Index. This should point to a repository compliant with PEP 503 (the simple repository API) or a local directory laid out in the same format.
|Extra URLs of package indexes to use in addition to --index-url. Should follow the same rules as --index-url.
|Ignore package index (only looking at --find-links URLs instead).
Some Examples of pip list command with options:
a) Pip List all the installed packages with version (with the default column formatting).
c) List all outdated Packages that are not dependencies of other packages.
d) pip list – list all the packages installed using json formatting
e) pip list using freeze formatting
f) pip list – python List packages that are not dependencies of installed packages.
g) pip list – python list all package that are upto date.
2. Get the list of all the packages in python Using Help function:
To get the list of installed packages in python you can simply type the below command in python IDE
This will list all the modules installed in the system .
3. List all the packages, modules installed in python Using pip freeze:
Open command prompt on your windows and type the following command
This will get the list of installed packages along with their version as shown below
These are the three different methods that lists the packages or libraries installed in python.