Skip to content

Retrieve and print Python package dependencies.

License

Notifications You must be signed in to change notification settings

Midnighter/dependency-info

Folders and files

NameName
Last commit message
Last commit date

Latest commit

698a06a · May 29, 2022
May 29, 2022
May 29, 2022
May 29, 2022
May 29, 2022
Oct 11, 2020
Apr 28, 2018
Feb 7, 2019
May 29, 2022
Apr 28, 2018
Oct 11, 2020
Feb 3, 2021
May 29, 2022
May 29, 2022
Oct 11, 2020
May 29, 2022

Repository files navigation

Package Dependency Information

Current PyPI Version Supported Python Versions Apache Software License Version 2.0 Code of Conduct GitHub Actions Codecov Code Style Black
from depinfo import print_dependencies


def show_versions():
    print_dependencies("your-package-name")

That's all there is to it.

If instead you want to access and modify the information, you can make use of the underlying functions that return dictionaries that map package names to their current versions. By default it will include common build packages such as pip.

from depinfo import get_pkg_info
help(get_pkg_info)

Example

from depinfo import print_dependencies
print_dependencies("depinfo")
System Information
==================
OS                     Linux
OS-release 4.4.0-122-generic
Python                 3.6.5

Package Versions
================
pip        10.0.1
setuptools 39.0.1
wheel      0.31.0

Copyright