python-spdx-tools
Port variant v15
Summary SPDX parser and tools (3.15)
Package version 0.8.5
Homepage https://github.com/spdx/tools-python
Keywords python
Maintainer Python Automaton
License Not yet specified
Other variants v14
Ravenports Buildsheet | History
Ravensource Port Directory | History
Last modified 27 NOV 2026, 01:15:48 UTC
Port created 27 NOV 2026, 01:15:48 UTC
Subpackage Descriptions
single # Python library to parse, validate and create SPDX documents CI status (Linux, macOS and Windows): [![Install and Test][1]][2] [1]: https://github.com/spdx/tools-python/actions/workflows/install_and_test.yml/badge.svg [2]: https://github.com/spdx/tools-python/actions/workflows/install_and_test.yml ## Breaking changes v0.7 -> v0.8 Please be aware that the upcoming 0.8 release has undergone a significant refactoring in preparation for the upcoming SPDX v3.0 release, leading to breaking changes in the API. Please refer to the [migration guide] to update your existing code. The main features of v0.8 are: - full validation of SPDX documents against the v2.2 and v2.3 specification - support for SPDX's RDF format with all v2.3 features - experimental support for the upcoming SPDX v3 specification. Note, however, that support is neither complete nor stable at this point, as the spec is still evolving. SPDX3-related code is contained in a separate subpackage "spdx3" and its use is optional. We do not recommend using it in production code yet. Note that v0.8 only supports **writing**, not **reading** SPDX 3.0 documents. See [#760] for details. ## Information This library implements SPDX parsers, convertors, validators and handlers in Python. - Home: - Issues: - PyPI: - Browse the API: Important updates regarding this library are shared via the SPDX tech mailing list: . ## License [Apache-2.0] ## Features - API to create and manipulate SPDX v2.2 and v2.3 documents - Parse, convert, create and validate SPDX files - Supported formats: Tag/Value, RDF, JSON, YAML, XML - Visualize the structure of a SPDX document by creating an `AGraph`. Note: This is an optional feature and requires additional installation of optional dependencies ## Experimental support for SPDX 3.0 - Create v3.0 elements and payloads - Convert v2.2/v2.3 documents to v3.0 - Serialize to JSON-LD See [Quickstart to SPDX 3.0] below. The implementation is based on the descriptive Markdown files in the repository (commit: a5372a3c145dbdfc1381fc1f791c68889aafc7ff). The latest SPDX 3.0 model is available at . ## Installation As always you should work in a virtualenv (venv). You can install a local clone of this repo with `yourenv/bin/pip install .` or install it from PyPI (check for the [newest release] and install it like `yourenv/bin/pip install spdx-tools==0.8.3`). Note that on Windows it would be `Scripts` instead of `bin`. ## How to use ### Command-line usage 1. **PARSING/VALIDATING** (for parsing any format): - Use `pyspdxtools -i ` where `` is the location of the file. The input format is inferred automatically from the file ending. - If you are using a source distribution, try running: `pyspdxtools -i tests/spdx/data/SPDXJSONExample-v2.3.spdx.json` 2. **CONVERTING** (for converting one format to another): - Use `pyspdxtools -i -o ` where `` is the location of the file to be converted and `` is the location of the output file. The input and output formats are inferred automatically from the file endings.
Configuration Switches (platform-specific settings discarded)
PY314 OFF Build using Python 3.14 PY315 ON Build using Python 3.15
Package Dependencies by Type
Build (only) python315:dev:std
python-pip:single:v15
autoselect-python:single:std
Build and Runtime python315:primary:std
Runtime (only) python-beartype:single:v15
python-click:single:v15
python-license-expression:single:v15
python-ply:single:v15
python-PyYAML:single:v15
python-rdflib:single:v15
python-semantic-version:single:v15
python-uritools:single:v15
python-xmltodict:single:v15
Download groups
main mirror://PYPIWHL/88/f5/1ac402e1f8d253fa60ac167c4a1fb7eeb0f29a04942788e2d43c984cd749
Distribution File Information
7c2d5865941be9d2e898f5b084e8d5422dd298dc5a29320ddb198fec304f59c4 286573 python-src/spdx_tools-0.8.5-py3-none-any.whl
Ports that require python-spdx-tools:v15
python-sbom:v15 Tree shaking for the minimal viable SBOM (3.15)