No project description provided
Project description
# Craft Platforms
[](https://github.com/canonical/craft-platforms/actions/workflows/qa.yaml) [](https://canonical-craft-platforms.readthedocs-hosted.com) [](https://pypi.org/project/craft-platforms) [](https://github.com/astral-sh/ruff) [](https://github.com/canonical/craft-platforms/actions/workflows/security-scan.yaml)
Craft Platforms is a library that handles platform information for Snapcraft, Charmcraft, Rockcraft, and other craft apps. A platform in this sense is the combination of an operating system version and its target architecture.
The library’s primary function is to parse information in a craft project file, such as snapcraft.yaml, and creates a build plan from it. The plan is a manifest for environments, describing those where the artifact can build and run.
This library is most useful for developers who build apps with the [Craft Application](https://canonical-craft-application.readthedocs-hosted.com) library.
## Basic usage
Craft Platforms creates exhaustive build plans for any craft-like data structure, taking into account differences between applications.
`terminal >>> import craft_platforms >>> craft_platforms.get_build_plan( ... "mycraft", ... project_data={"base": "debian@14", "platforms": {"riscv64": None}} ... ) [BuildInfo(platform='riscv64', build_on='riscv64', build_for='riscv64', build_base=DistroBase(distribution='debian', series='14'))] `
## Installation
Craft Platforms is a pure Python library that runs on Python 3.8 or later. It can be installed from [PyPI](https://pypi.org/project/craft-platforms)
## Documentation
The [Craft Platforms documentation](https://canonical-craft-platforms.readthedocs-hosted.com) contains reference information for the library.
## Community and support
You can report any issues or bugs on the project’s [GitHub repository](https://github.com/canonical/craft-platforms/issues).
Craft Platforms is covered by the [Ubuntu Code of Conduct](https://ubuntu.com/community/ethos/code-of-conduct).
## Contribute to Craft Platforms
Craft Platforms is open source and part of the Canonical family. We would love your help.
If you’re interested, start with the [contribution guide](HACKING.rst).
We welcome any suggestions and help with the docs. The [Canonical Open Documentation Academy](https://github.com/canonical/open-documentation-academy) is the hub for doc development, including Craft Platforms docs. No prior coding experience is required.
## License and copyright
Craft Platforms is released under the [LGPL-3.0 license](LICENSE).
© 2023-2025 Canonical Ltd.
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file craft_platforms-0.11.1.tar.gz.
File metadata
- Download URL: craft_platforms-0.11.1.tar.gz
- Upload date:
- Size: 355.3 kB
- Tags: Source
- Uploaded using Trusted Publishing? Yes
- Uploaded via: twine/6.1.0 CPython/3.13.12
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
5807e2b727c0cb9c7c85e5ecaf4181ed1b3f89e6232464736369dcb871ae9339
|
|
| MD5 |
48ca4061a1d53772e9d62e768c0361eb
|
|
| BLAKE2b-256 |
93b9b7bef735949e73756910d85c1d4178e5c6523b70e5dbe5477ab0c2fd8d81
|
Provenance
The following attestation bundles were made for craft_platforms-0.11.1.tar.gz:
Publisher:
release-publish.yaml on canonical/craft-platforms
-
Statement:
-
Statement type:
https://in-toto.io/Statement/v1 -
Predicate type:
https://docs.pypi.org/attestations/publish/v1 -
Subject name:
craft_platforms-0.11.1.tar.gz -
Subject digest:
5807e2b727c0cb9c7c85e5ecaf4181ed1b3f89e6232464736369dcb871ae9339 - Sigstore transparency entry: 1262696831
- Sigstore integration time:
-
Permalink:
canonical/craft-platforms@4879309ce195c712805edacedae067129a392ec9 -
Branch / Tag:
refs/tags/0.11.1 - Owner: https://github.com/canonical
-
Access:
public
-
Token Issuer:
https://token.actions.githubusercontent.com -
Runner Environment:
self-hosted -
Publication workflow:
release-publish.yaml@4879309ce195c712805edacedae067129a392ec9 -
Trigger Event:
push
-
Statement type:
File details
Details for the file craft_platforms-0.11.1-py3-none-any.whl.
File metadata
- Download URL: craft_platforms-0.11.1-py3-none-any.whl
- Upload date:
- Size: 37.9 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? Yes
- Uploaded via: twine/6.1.0 CPython/3.13.12
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
740dc7ba7f508a2fe8f3f8f8a6784fd70d48b36a2930a418a19c69cefe68d398
|
|
| MD5 |
037dfda595f44097e55fa9c202e40c61
|
|
| BLAKE2b-256 |
4277d2a19bde5e05ec30eef8f63f6f6e1cde9c4f07be5da7fb71a675e159eec2
|
Provenance
The following attestation bundles were made for craft_platforms-0.11.1-py3-none-any.whl:
Publisher:
release-publish.yaml on canonical/craft-platforms
-
Statement:
-
Statement type:
https://in-toto.io/Statement/v1 -
Predicate type:
https://docs.pypi.org/attestations/publish/v1 -
Subject name:
craft_platforms-0.11.1-py3-none-any.whl -
Subject digest:
740dc7ba7f508a2fe8f3f8f8a6784fd70d48b36a2930a418a19c69cefe68d398 - Sigstore transparency entry: 1262696908
- Sigstore integration time:
-
Permalink:
canonical/craft-platforms@4879309ce195c712805edacedae067129a392ec9 -
Branch / Tag:
refs/tags/0.11.1 - Owner: https://github.com/canonical
-
Access:
public
-
Token Issuer:
https://token.actions.githubusercontent.com -
Runner Environment:
self-hosted -
Publication workflow:
release-publish.yaml@4879309ce195c712805edacedae067129a392ec9 -
Trigger Event:
push
-
Statement type: