How to check the version of the currently installed `pdb` (Python Debugger)?

Question:

To check the version of the specific python module, I heard that the following is one of the standard way:

python -c 'import some_module; print (__some_module__.version)'

But for the python debugger ‘pdb’, the above idea doesn’t work. Then how can we check the version of the currently installed pdb?

Asked By: chanwcom

||

Answers:

pip freeze will list all currently installed packages

pip freeze | grep pdb
Answered By: Iain Shelvington

pdb is a Python standard library. So the version of your Python is the version of your pdb (if we can talk about versions at all. You would usually say, pdb in Python X)

Read: https://docs.python.org/3/library/pdb.html

Answered By: Prayson W. Daniel

Since pdb is in the standard library it uses pythons version number and does not have a version number of its own.

In general, modules in the standard library SHOULD NOT have version numbers. They implicitly carry the version number of the Python release they are included in.

https://www.python.org/dev/peps/pep-0396/

Answered By: James
Categories: questions Tags: ,
Answers are sorted by their score. The answer accepted by the question owner as the best is marked with
at the top-right corner.