Use pkg_resources. Anything installed from PyPI at least should have a version number.
>>> import pkg_resources
>>> pkg_resources.get_distribution("blogofile").version
'0.7.1'
More Related Contents:
- What is __init__.py for?
- How do I check what version of Python is running my script?
- How to retrieve a module’s path?
- Generate random numbers with a given (numerical) distribution
- How do I compare version numbers in Python?
- What does a . in an import statement in Python mean?
- What’s the difference between a Python module and a Python package?
- Python 3: ImportError “No Module named Setuptools”
- Adding a module (Specifically pymorph) to Spyder (Python IDE)
- How to import a Python class that is in a directory above?
- Defining private module functions in python
- Python – Module Not Found
- Upgrade python in a virtualenv
- How does Python importing exactly work?
- ImportError after cython embed
- How to import a module in Python with importlib.import_module
- How to programmatically set a global (module) variable?
- How to prevent a module from being imported twice?
- Python way to clone a git repository
- Return a list of imported Python modules used in a script?
- Import a python module without running it
- ImportError: No module named six
- How to make global imports from a function?
- Where are the python modules stored?
- Module not found error in VS code despite the fact that I installed it
- Flask(‘application’) versus Flask(__name__)
- Error: No module named ‘fcntl’
- How do you organize Python modules? [closed]
- Module Not Found – No module named
- What’s the difference between a module and package in Python?