Distinfo
distinfo is a tool for extracting metadata, including full dependencies, from
Python source distributions.
Usage
CLI
Dump json metadata to stdout:
$ distinfo /path/to/package/source
Library
Print dependencies and metadata:
>>> from distinfo import Distribution, dump
>>>
>>> dist = Distribution("/path/to/package/source")
>>> dump(dist.requires)
{
"build": [
"setuptools-scm"
],
"dev": [
"pycmd",
],
"run": [
"click",
"requests",
],
"test": [
"pytest",
]
}
>>> dump(dist.metadata)
{
"author": "A N Other",
"author_email": "a@example.org",
"extensions": {
"distinfo": {
"imports": {
"distinfo": [
"click",
"requests"
],
"tests": [
"pytest",
]
},
"tests": [
"tests",
],
}
},
"license": "GPL-3.0-or-later",
"metadata_version": "2.1",
"name": "example",
"provides_extra": [
"build",
"dev",
"test"
],
"requires_dist": [
"click",
"pycmd; extra == 'dev'",
"pytest; extra == 'test'",
"requests"
"setuptools-scm; extra == 'build'",
],
"summary": "Example package",
"version": "0.0.0"
}
Specifications
https://packaging.python.org/specifications/
Metadata
- PEP 241 - Metadata for Python Software Packages 1.0
- PEP 314 - Metadata for Python Software Packages 1.1
- PEP 345 - Metadata for Python Software Packages 1.2
- PEP 426 - Metadata for Python Software Packages 2.0
- PEP 566 - Metadata for Python Software Packages 2.1
- PEP 459 -- Standard Metadata Extensions for Python Software Packages
Dependencies
Metadata
Release files for distinfo 0.2.0
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | Provenance | |
|---|---|---|---|---|
| distinfo-0.2.0.tar.gz | 28.7 kB | Without provenance | Details |
Release files / distinfo-0.2.0.tar.gz
| Download URL | distinfo-0.2.0.tar.gz |
|---|---|
| Size | 28.7 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
115c3df7196989f7f7276179a3090f8a00040d350eb4d0cb8cc8d30fc91be1fa
|
|
BLAKE2b-256 checksum How to use checksums |
9aeefd85e003b281ac6570db918fcde3322d1942c66594c1a876821071e1ae69
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
Security for distinfo 0.2.0
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
No provenance found
None of the files in this release were uploaded with provenance metadata.
A note on package security
PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.
To learn more about protecting yourself from malicious actors, visit our package security documentation.