bundle.pybind

Submodules

Classes

Pybind

Orchestrates reading pyproject.toml, applying plugins, resolving module specs,

Package Contents

class bundle.pybind.Pybind(pyproject_path: pathlib.Path | str, plugins: list[object] | None = None)[source]

Orchestrates reading pyproject.toml, applying plugins, resolving module specs, and constructing Extension objects via extension.make_extension.

pyproject
base_dir
spec
resolver
resolved: bundle.pybind.resolved.ProjectResolved | None = None
plugins: list[object] = []
register_plugin(plugin: object) None[source]
async apply_spec_plugins() None[source]

Run all PybindPluginSpec instances against raw module specs.

async apply_resolved_plugins() None[source]

Run all PybindPluginResolved instances against resolved modules.

async resolve() bundle.pybind.resolved.ProjectResolved[source]
async get_spec_extensions() list[bundle.pybind.extension.ExtensionBuild][source]

Resolve the project and build all Extension objects concurrently.

classmethod setup(invoking_file: pathlib.Path | str, **kwargs) None[source]

Entry point for setup.py: build Extension list and invoke setuptools.setup.

classmethod build(path: str, parallel: int = multiprocessing.cpu_count())[source]
Async:

Shell out to python setup.py build_ext with optional parallel.

classmethod info(path: str)[source]
Async:

Load and resolve project for inspection without building.