Skip to content

Commit

Permalink
Configure maturin's Cargo.toml path directly in pyproject
Browse files Browse the repository at this point in the history
  • Loading branch information
aborgna-q committed Nov 2, 2023
1 parent ea84f57 commit 9125156
Show file tree
Hide file tree
Showing 4 changed files with 6 additions and 5 deletions.
4 changes: 2 additions & 2 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -110,7 +110,7 @@ jobs:
- name: Build pyo3 bindings
run: |
pip install -r requirements.txt
maturin build -m pytket-tk2/Cargo.toml
maturin build
pip install target/wheels/*.whl
- name: Test pyo3 bindings
run: |
Expand Down Expand Up @@ -158,7 +158,7 @@ jobs:
run: |
pip install -r requirements.txt
pip install pytest-cov
maturin build -m pytket-tk2/Cargo.toml
maturin build
pip install target/wheels/*.whl
- name: Run python tests with coverage instrumentation
run: |
Expand Down
2 changes: 1 addition & 1 deletion DEVELOPMENT.md
Original file line number Diff line number Diff line change
Expand Up @@ -62,7 +62,7 @@ cargo +nightly miri test
To run the python tests, run:

```bash
maturin develop -m pytket-tk2/Cargo.toml
maturin develop
pytest
```

Expand Down
4 changes: 2 additions & 2 deletions justfile
Original file line number Diff line number Diff line change
Expand Up @@ -12,11 +12,11 @@ fix:

# Build the python package wheels
pybuild:
maturin build -m pytket-tk2/Cargo.toml --release
maturin build --release

# Build the python package for local development
pydevelop:
maturin develop -m pytket-tk2/Cargo.toml
maturin develop

# Run the python tests
pytest: pydevelop
Expand Down
1 change: 1 addition & 0 deletions pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -38,6 +38,7 @@ homepage = "https://github.com/CQCL/tket2"
repository = "https://github.com/CQCL/tket2"

[tool.maturin]
manifest-path = "pytket-tk2/Cargo.toml"
python-source = "pytket-tk2"

[tool.pytest.ini_options]
Expand Down

0 comments on commit 9125156

Please sign in to comment.