Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
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
6 changes: 2 additions & 4 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -52,6 +52,7 @@ jobs:
args: >
-DPYBIND11_FINDPYTHON=OFF
-DCMAKE_CXX_FLAGS="-D_=1"
-DPYBIND11_NUMPY_1_ONLY=ON
exercise_D_: 1
- runs-on: windows-2019
python: '3.8'
Expand All @@ -65,6 +66,7 @@ jobs:
python: '3.9'
args: >
-DCMAKE_MSVC_RUNTIME_LIBRARY=MultiThreaded
-DPYBIND11_NUMPY_1_ONLY=ON
- runs-on: windows-2022
python: '3.10'
args: >
Expand Down Expand Up @@ -149,14 +151,12 @@ jobs:

# First build - C++11 mode and inplace
# More-or-less randomly adding -DPYBIND11_SIMPLE_GIL_MANAGEMENT=ON here
# (same for PYBIND11_NUMPY_1_ONLY, but requires a NumPy 1.x at runtime).
- name: Configure C++11 ${{ matrix.args }}
run: >
cmake -S . -B .
-DPYBIND11_WERROR=ON
-DPYBIND11_DISABLE_HANDLE_TYPE_NAME_DEFAULT_IMPLEMENTATION=ON
-DPYBIND11_SIMPLE_GIL_MANAGEMENT=ON
-DPYBIND11_NUMPY_1_ONLY=ON
-DPYBIND11_PYTEST_ARGS=-v
-DDOWNLOAD_CATCH=ON
-DDOWNLOAD_EIGEN=ON
Expand All @@ -180,13 +180,11 @@ jobs:

# Second build - C++17 mode and in a build directory
# More-or-less randomly adding -DPYBIND11_SIMPLE_GIL_MANAGEMENT=OFF here.
# (same for PYBIND11_NUMPY_1_ONLY, but requires a NumPy 1.x at runtime).
- name: Configure C++17
run: >
cmake -S . -B build2
-DPYBIND11_WERROR=ON
-DPYBIND11_SIMPLE_GIL_MANAGEMENT=OFF
-DPYBIND11_NUMPY_1_ONLY=ON
-DPYBIND11_PYTEST_ARGS=-v
-DDOWNLOAD_CATCH=ON
-DDOWNLOAD_EIGEN=ON
Expand Down
18 changes: 11 additions & 7 deletions noxfile.py
Original file line number Diff line number Diff line change
@@ -1,11 +1,16 @@
#!/usr/bin/env -S uv run

# /// script
# dependencies = ["nox>=2025.2.9"]
# ///

from __future__ import annotations

import argparse

import nox

nox.needs_version = ">=2024.3.2"
nox.options.sessions = ["lint", "tests", "tests_packaging"]
nox.needs_version = ">=2025.2.9"
nox.options.default_venv_backend = "uv|virtualenv"


Expand Down Expand Up @@ -49,7 +54,7 @@ def tests_packaging(session: nox.Session) -> None:
session.run("pytest", "tests/extra_python_package", *session.posargs)


@nox.session(reuse_venv=True)
@nox.session(reuse_venv=True, default=False)
def docs(session: nox.Session) -> None:
"""
Build the docs. Pass --non-interactive to avoid serving.
Expand Down Expand Up @@ -83,16 +88,15 @@ def docs(session: nox.Session) -> None:
session.run("sphinx-build", "--keep-going", *shared_args)


@nox.session(reuse_venv=True)
@nox.session(reuse_venv=True, default=False)
def make_changelog(session: nox.Session) -> None:
"""
Inspect the closed issues and make entries for a changelog.
"""
session.install("ghapi", "rich")
session.run("python", "tools/make_changelog.py")
session.install_and_run_script("tools/make_changelog.py")


@nox.session(reuse_venv=True)
@nox.session(reuse_venv=True, default=False)
def build(session: nox.Session) -> None:
"""
Build SDists and wheels.
Expand Down
21 changes: 12 additions & 9 deletions tests/requirements.txt
Original file line number Diff line number Diff line change
@@ -1,13 +1,16 @@
--only-binary=:all:
build~=1.0; python_version>="3.8"
build>=1
numpy~=1.23.0; python_version=="3.8" and platform_python_implementation=="PyPy"
numpy~=1.25.0; python_version=="3.9" and platform_python_implementation=='PyPy'
numpy~=1.25.0; python_version=="3.9" and platform_python_implementation=="PyPy"
numpy~=2.2.0; python_version=="3.10" and platform_python_implementation=="PyPy"
numpy~=1.26.0; platform_python_implementation=="GraalVM" and sys_platform=="linux"
numpy~=1.21.5; platform_python_implementation!="PyPy" and platform_python_implementation!="GraalVM" and python_version>="3.8" and python_version<"3.10"
numpy~=1.22.2; platform_python_implementation!="PyPy" and platform_python_implementation!="GraalVM" and python_version=="3.10"
numpy~=1.26.0; platform_python_implementation!="PyPy" and platform_python_implementation!="GraalVM" and python_version>="3.11" and python_version<"3.13"
pytest~=7.0
numpy~=1.21.5; platform_python_implementation=="CPython" and python_version>="3.8" and python_version<"3.10"
numpy~=1.22.2; platform_python_implementation=="CPython" and python_version=="3.10"
numpy~=1.26.0; platform_python_implementation=="CPython" and python_version>="3.11" and python_version<"3.13"
numpy~=2.2.0; platform_python_implementation=="CPython" and python_version=="3.13"
pytest>=7
pytest-timeout
scipy~=1.5.4; platform_python_implementation!="PyPy" and platform_python_implementation!="GraalVM" and python_version<"3.10"
scipy~=1.8.0; platform_python_implementation!="PyPy" and platform_python_implementation!="GraalVM" and python_version=="3.10" and sys_platform!='win32'
scipy~=1.11.1; platform_python_implementation!="PyPy" and platform_python_implementation!="GraalVM" and python_version>="3.11" and python_version<"3.13" and sys_platform!='win32'
scipy~=1.5.4; platform_python_implementation=="CPython" and python_version<"3.10"
scipy~=1.8.0; platform_python_implementation=="CPython" and python_version=="3.10" and sys_platform!="win32"
scipy~=1.11.1; platform_python_implementation=="CPython" and python_version>="3.11" and python_version<"3.13" and sys_platform!="win32"
scipy~=1.15.2; platform_python_implementation=="CPython" and python_version=="3.13" and sys_platform!="win32"
7 changes: 6 additions & 1 deletion tools/make_changelog.py
Original file line number Diff line number Diff line change
@@ -1,4 +1,9 @@
#!/usr/bin/env python3
#!/usr/bin/env -S uv run

# /// script
# dependencies = ["ghapi", "rich"]
# ///

from __future__ import annotations

import re
Expand Down
Loading