Skip to main content

No project description provided

Project description

hatch-buildext

PyPI - Version PyPI - Python Version Checks & Tests


Table of Contents

Usage

The only key currently recognised is extensions. This should be a map of key-value pairs mapping the extension name to a resolver.

# pyproject.toml
[tool.hatch.build.targets.wheel.hooks.buildext]
dependencies = ["hatch-buildext"]

[tool.hatch.build.targets.wheel.hooks.buildext.extensions]
libsome = "path.to.resolver"
libother =  "path.to.another"

Example

For instance, if using src layout, the directory structure could look as follows:

.
├── LICENSE.txt
├── README.md
├── pyproject.toml
├── src
│   ├── resolvers
│   │   ├── lib_a.py
│   │   └── lib_b.py
│   ├── liba
│   │   ├── foo.h
│   │   └── foo.c
│   ├── libb
│   │   ├── bar.h
│   │   └── bar.c
│   └── mypackage
│       ├── __about__.py
│       ├── __init__.py
│       ├── ...
│       └── core.py
└── tests
    ├── __init__.py
    ├── conftest.py
    ├── ...
    └── test_core.py

Then, if that you want to include both libraries as module extensions in mypackage, the extensions configuration would look as follows:

[tool.hatch.build.targets.wheel.hooks.buildext.extensions]
"mypackage.lib_a" = "src.resolvers.lib_a"
"mypackage.lib_b" =  "src.resolvers.lib_b"

[!WARNING] The configuration may change at any time until this package is stable.

Resolvers

Resolvers may implement or omit any part of the interface here. Each function will be passed the root of of the project directory while building, in order to make it easier to provide paths to build requirements in the project tree.

The meaning of these functions are identical to those in the setuptools Extension API.

[!WARNING] The interface may change at any time until this package is stable.

License

hatch-buildext is distributed under the terms of the Apache-2.0 license.

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

hatch_buildext-0.3.1.tar.gz (10.7 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

hatch_buildext-0.3.1-py3-none-any.whl (12.0 kB view details)

Uploaded Python 3

File details

Details for the file hatch_buildext-0.3.1.tar.gz.

File metadata

  • Download URL: hatch_buildext-0.3.1.tar.gz
  • Upload date:
  • Size: 10.7 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.1.0 CPython/3.13.7

File hashes

Hashes for hatch_buildext-0.3.1.tar.gz
Algorithm Hash digest
SHA256 985154ecaaa6f20c26041fc89d0f387b5eff7939b4200a9771527acec46f3798
MD5 e06bc86491ab4e39906b3001becae776
BLAKE2b-256 a960ed760ceff6698254ff0a0da7a223510b4aeb322fc8beba7f7f570bb7dd19

See more details on using hashes here.

Provenance

The following attestation bundles were made for hatch_buildext-0.3.1.tar.gz:

Publisher: release.yml on xoudini/hatch-buildext

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

File details

Details for the file hatch_buildext-0.3.1-py3-none-any.whl.

File metadata

  • Download URL: hatch_buildext-0.3.1-py3-none-any.whl
  • Upload date:
  • Size: 12.0 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.1.0 CPython/3.13.7

File hashes

Hashes for hatch_buildext-0.3.1-py3-none-any.whl
Algorithm Hash digest
SHA256 5213cd144a66c9b824d23d1557ef2a8c2a0d2086eee99554b6cb2d1eea3ba2a8
MD5 7c458c0a8a0e306b1422059e6fb30d63
BLAKE2b-256 560d374a3390909890ea3e8cac319d1cf86548b2a06929c73479a3d6e71785a6

See more details on using hashes here.

Provenance

The following attestation bundles were made for hatch_buildext-0.3.1-py3-none-any.whl:

Publisher: release.yml on xoudini/hatch-buildext

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page