Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
68 commits
Select commit Hold shift + click to select a range
ff76ef8
Remove retworkx and Python 3.9 support
IvanIsCoding Sep 21, 2025
729755d
Add release notes for Python 3.9 EoL
IvanIsCoding Sep 21, 2025
2fbb343
Add retworkx removal release note
IvanIsCoding Sep 21, 2025
7df0fe9
Merge remote-tracking branch 'upstream/main' into remove-39-retworkx
IvanIsCoding Sep 21, 2025
3084019
Drop 3.9 support in pyproject.toml and uv
IvanIsCoding Sep 21, 2025
1dd621c
Bump other 39 -> 310 related things
IvanIsCoding Sep 21, 2025
f52487b
Merge remote-tracking branch 'upstream/main' into remove-39-retworkx
IvanIsCoding Oct 24, 2025
e5ca8f4
use 3.14 not 3.14-dev
IvanIsCoding Oct 24, 2025
78ce745
Move note to upgrade
IvanIsCoding Oct 24, 2025
711cfdc
Upgrade packages to support 3.14
IvanIsCoding Nov 2, 2025
03afe1b
Allowlist missing __all__ for mypy
IvanIsCoding Nov 2, 2025
a222850
Add 3.14 to workflow
IvanIsCoding Nov 2, 2025
7c87aa7
Add release note
IvanIsCoding Nov 2, 2025
fe13da0
Use Python 3.12 for release
IvanIsCoding Nov 2, 2025
03e6329
Skip Python 3.9
IvanIsCoding Nov 2, 2025
1ebe14a
Skip 3.14 free-threaded build
IvanIsCoding Nov 2, 2025
5b76c1f
Bump nox as well
IvanIsCoding Nov 3, 2025
e33e188
Merge branch 'main' into remove-39-retworkx
IvanIsCoding Nov 4, 2025
b875800
Merge branch 'main' into upgrade-314
IvanIsCoding Nov 4, 2025
795ad00
Use ruff
IvanIsCoding Nov 30, 2025
9b124f5
Use ruff in CI
IvanIsCoding Nov 30, 2025
6ea0993
Merge branch 'main' into ruff-format
IvanIsCoding Nov 30, 2025
435fb73
Merge branch 'main' into ruff-format
IvanIsCoding Dec 5, 2025
a2c5ea0
Merge branch 'main' into upgrade-314
IvanIsCoding Dec 5, 2025
7bd603c
Merge branch 'main' into remove-39-retworkx
IvanIsCoding Dec 5, 2025
b9d1a15
Use macos-15-intel for tests
IvanIsCoding Dec 13, 2025
cfa1ae6
Update wheels.yml to use macos-15-intel
IvanIsCoding Dec 13, 2025
418b6fc
Merge branch 'remove-39-retworkx' into upgrade-314
IvanIsCoding Dec 13, 2025
9e0b0b3
Merge branch 'upgrade-314' into ruff-format
IvanIsCoding Dec 13, 2025
11b9252
Merge branch 'main' into upgrade-314
IvanIsCoding Dec 13, 2025
b5600b9
Merge branch 'main' into ruff-format
IvanIsCoding Dec 13, 2025
ed086f9
Migrate to maturin
IvanIsCoding Dec 14, 2025
a3b4b07
Faster docs build
IvanIsCoding Dec 14, 2025
f443243
Try to fix coverage build
IvanIsCoding Dec 14, 2025
b8ce8cd
Use the PROFILE environment variable
IvanIsCoding Dec 14, 2025
ebe63c7
Another attempt
IvanIsCoding Dec 14, 2025
14f35bc
use release directory
IvanIsCoding Dec 14, 2025
bf72c35
Merge remote-tracking branch 'upstream/main' into upgrade-314
IvanIsCoding Dec 16, 2025
f53d0bc
Apply suggestions from code review
IvanIsCoding Dec 16, 2025
42ad1e1
Merge branch 'upgrade-314' into ruff-format
IvanIsCoding Dec 16, 2025
a4b4b77
Merge branch 'ruff-format' into free-threaded-314
IvanIsCoding Dec 16, 2025
25f0345
Reflect cibuildwheel in uv
IvanIsCoding Dec 16, 2025
c5d5c0d
Merge branch 'upgrade-314' into ruff-format
IvanIsCoding Dec 16, 2025
d52e23a
Merge branch 'ruff-format' into free-threaded-314
IvanIsCoding Dec 16, 2025
c4b9f4e
Merge branch 'main' into upgrade-314
IvanIsCoding Jan 1, 2026
f9a9a09
Merge branch 'upgrade-314' into ruff-format
IvanIsCoding Jan 1, 2026
2d78c29
Merge branch 'ruff-format' into free-threaded-314
IvanIsCoding Jan 1, 2026
9993727
Merge branch 'main' into ruff-format
IvanIsCoding Jan 29, 2026
d0082b8
Merge branch 'main' into ruff-format
IvanIsCoding Jan 29, 2026
3bc5342
Merge branch 'main' into ruff-format
IvanIsCoding Jan 29, 2026
9a802ea
Merge branch 'main' into ruff-format
IvanIsCoding Jan 29, 2026
999ca10
Merge branch 'ruff-format' into free-threaded-314
IvanIsCoding Jan 29, 2026
6a7153c
Upgradw uvlock
IvanIsCoding Jan 29, 2026
9ee3e3b
Minimize uv lock diff
IvanIsCoding Jan 30, 2026
d413134
Minimize uv lock diff
IvanIsCoding Jan 30, 2026
12f71e5
Merge branch 'ruff-format' into free-threaded-314
IvanIsCoding Jan 30, 2026
989ead8
Merge branch 'main' into ruff-format
IvanIsCoding Jan 30, 2026
0b61e70
Merge branch 'ruff-format' into free-threaded-314
IvanIsCoding Jan 30, 2026
d55900d
Merge branch 'main' into ruff-format
IvanIsCoding Jan 30, 2026
2145077
Merge branch 'main' into free-threaded-314
IvanIsCoding Jan 30, 2026
0886043
Merge branch 'main' into ruff-format
IvanIsCoding Feb 1, 2026
c8e42a0
Merge remote-tracking branch 'origin/ruff-format' into free-threaded-314
IvanIsCoding Feb 1, 2026
8f086f7
Merge branch 'main' into ruff-format
IvanIsCoding Feb 17, 2026
d55ab88
Merge branch 'ruff-format' into free-threaded-314
IvanIsCoding Feb 17, 2026
2c13964
Merge remote-tracking branch 'upstream/main' into free-threaded-314
IvanIsCoding Mar 22, 2026
d28a610
Merge remote-tracking branch 'upstream/main' into free-threaded-314
IvanIsCoding Mar 22, 2026
18141a7
Merge remote-tracking branch 'upstream/main' into free-threaded-314
IvanIsCoding Mar 28, 2026
2d451da
Merge branch 'main' into free-threaded-314
IvanIsCoding Mar 31, 2026
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
11 changes: 9 additions & 2 deletions .github/workflows/main.yml
Original file line number Diff line number Diff line change
Expand Up @@ -146,7 +146,14 @@ jobs:
- name: Build rustworkx
run: pip install .
env:
SETUPTOOLS_RUST_CARGO_PROFILE: "dev"
CARGO_PROFILE_RELEASE_OPT_LEVEL: "0"
CARGO_PROFILE_RELEASE_DEBUG: "true"
CARGO_PROFILE_RELEASE_DEBUG_ASSERTIONS: "true"
CARGO_PROFILE_RELEASE_OVERFLOW_CHECKS: "true"
CARGO_PROFILE_RELEASE_LTO: "false"
CARGO_PROFILE_RELEASE_PANIC: "unwind"
CARGO_PROFILE_RELEASE_INCREMENTAL: "true"
CARGO_PROFILE_RELEASE_CODEGEN_UNITS: "16"
CARGO_INCREMENTAL: 0
RUSTFLAGS: "-Cinstrument-coverage"
LLVM_PROFILE_FILE: "rustworkx-%p-%m.profraw"
Expand All @@ -158,7 +165,7 @@ jobs:
run: |
set -e
mv tests/rustworkx*profraw .
./grcov . --binary-path ./target/debug/ -s . -t lcov --branch --ignore-not-existing --ignore "/*" -o ./coveralls.lcov
./grcov . --binary-path ./target/release/ -s . -t lcov --branch --ignore-not-existing --ignore "/*" -o ./coveralls.lcov
- uses: actions/upload-artifact@v4
with:
name: coverage
Expand Down
14 changes: 7 additions & 7 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -77,10 +77,10 @@ it just as it would if there was a prebuilt binary available.
> [!NOTE]
> To build from source you will need to ensure you have pip >=19.0.0
installed, which supports PEP-517, or that you have manually installed
`setuptools-rust>=1.9` prior to running `pip install rustworkx`. If you receive an
error about `setuptools-rust` not being found you should upgrade pip with
`pip install -U pip` or manually install `setuptools-rust` with
`pip install -U setuptools-rust` and try again.
`maturin>=1.9` prior to running `pip install rustworkx`. If you receive an
error about `maturin` not being found you should upgrade pip with
`pip install -U pip` or manually install `maturin` with
`pip install -U maturin>=1.9` and try again.

### Optional dependencies

Expand Down Expand Up @@ -134,7 +134,7 @@ git clone https://github.com/Qiskit/rustworkx.git
```

rustworkx uses [PyO3](https://github.com/pyo3/pyo3) and
[setuptools-rust](https://github.com/PyO3/setuptools-rust) to build the
[maturin](https://github.com/PyO3/maturin) to build the
python interface, which enables using standard python tooling to work. So,
assuming you have rust installed, you can easily install rustworkx into your
python environment using `pip`. Once you have a local clone of the repo, change
Expand Down Expand Up @@ -166,8 +166,8 @@ changes reflected in your python environment.
### Develop Mode

If you'd like to build rustworkx in debug mode and use an interactive debugger
while working on a change you can set `SETUPTOOLS_RUST_CARGO_PROFILE="dev"`
as an environment variable to build and install rustworkx in develop mode.
while working on a change you can run `maturin build --profile dev` to build rustworkx
and then install the wheel with `pip`.
This will build rustworkx without optimizations and include debuginfo
when running `pip install`. That can be handy for debugging.

Expand Down
4 changes: 3 additions & 1 deletion noxfile.py
Original file line number Diff line number Diff line change
Expand Up @@ -44,7 +44,9 @@ def docs(session):
session.env["UV_PROJECT_ENVIRONMENT"] = session.virtualenv.location
session.env["UV_FROZEN"] = "1"
# faster build as generating docs already takes some time and we discard the env
session.env["SETUPTOOLS_RUST_CARGO_PROFILE"] = "dev"
session.env["CARGO_PROFILE_RELEASE_OPT_LEVEL"] = "1"
session.env["CARGO_PROFILE_RELEASE_CODEGEN_UNITS"] = "16"
session.env["CARGO_PROFILE_RELEASE_LTO"] = "thin"
session.run("uv", "sync", "--only-group", "docs")
session.install(".")
session.run(
Expand Down
24 changes: 9 additions & 15 deletions pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -24,17 +24,11 @@ classifiers=[
]
keywords = ["Networks", "Network", "Graph", "Graph Theory", "DAG"]

[tool.setuptools]
packages = ["rustworkx", "rustworkx.visualization"]
include-package-data = true
[tool.maturin]
features = ["pyo3/extension-module"]
locked = true
bindings = "pyo3"

[tool.distutils.bdist_wheel]
py-limited-api = "cp310"

[[tool.setuptools-rust.ext-modules]]
target = "rustworkx.rustworkx"
path = "Cargo.toml"
binding = "PyO3"

[project.optional-dependencies]
mpl = ["matplotlib>=3.0"]
Expand All @@ -61,23 +55,23 @@ name = "Ivan Carvalho"
email = "ivancarvalho@gatech.edu"

[build-system]
requires = ["setuptools>=77.0.0", "setuptools-rust>=1.9"]
build-backend = "setuptools.build_meta"
requires = ["maturin>=1.9,<2.0"]
build-backend = "maturin"

[dependency-groups]
testinfra = [
"nox==2025.10.16",
"uv==0.11.2",
]
test = [
"setuptools-rust",
"maturin>=1.9.0,<2.0",
"testtools>=2.5.0",
"networkx>=3.2",
"stestr>=4.1",
]
lint = [
"ruff==0.15.7",
"setuptools-rust",
"maturin>=1.9.0,<2.0",
"typos~=1.39",
]
stubs = [
Expand Down Expand Up @@ -139,7 +133,7 @@ manylinux-i686-image = "manylinux2014"
skip = "pp* cp314t* *win32 *musllinux*i686"
test-requires = "networkx"
test-command = "python -m unittest discover {project}/tests"
before-build = "pip install -U setuptools-rust"
before-build = "pip install -U maturin>=1.9.0,<2.0"
test-skip = "*linux_s390x *ppc64le *i686 *win32"

[tool.cibuildwheel.linux]
Expand Down
54 changes: 28 additions & 26 deletions uv.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Loading