Skip to content

Fix: Update pyproject.toml for pixi and Hatch compatibility#1

Merged
TheFermiSea merged 1 commit intomainfrom
fix-pyproject-pixi-hatch
May 24, 2025
Merged

Fix: Update pyproject.toml for pixi and Hatch compatibility#1
TheFermiSea merged 1 commit intomainfrom
fix-pyproject-pixi-hatch

Conversation

@TheFermiSea
Copy link
Owner

Fix pyproject.toml and implement Hatch build

This commit addresses two issues in `pyproject.toml` to enable
successful packaging and installation with pixi and ensure
compatibility with the Hatch build backend.

1.  Added a `[package]` section:
    Pixi requires a `[package]` section in `pyproject.toml` (or
    equivalent in `pixi.toml`) to correctly identify and process
    the project as a Python package. This section, containing the
    package `name` and `version`, has been added.

2.  Corrected `packages` format for Hatch build:
    The `[tool.hatch.build.targets.wheel]` section had its `packages`
    directive as a single string. The Hatch build system expects this
    to be an array of strings. This has been corrected to
    `packages = ["elliptec_controller"]`.

With these changes, the package can be successfully added locally
to a pixi environment using a path-based installation and is
correctly configured for building with Hatch. For `pixi add --git <URL>`
to work, these changes must be pushed to the remote repository.
@TheFermiSea TheFermiSea merged commit 55db4fd into main May 24, 2025
0 of 4 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant