diff --git a/.github/workflows/build-wheels.yml b/.github/workflows/build-wheels.yml
index 517cd55..125c28c 100644
--- a/.github/workflows/build-wheels.yml
+++ b/.github/workflows/build-wheels.yml
@@ -52,7 +52,7 @@ jobs:
uses: pypa/cibuildwheel@v4.3.1
env:
# All cibuildwheel options are here (nothing "hidden" in pyproject.toml)
- CIBW_SKIP: "*-win32 *i686 cp3??t-* cp310-win_arm64"
+ CIBW_SKIP: "*-win32 *i686 cp313t-* cp310-win_arm64"
CIBW_BUILD_FRONTEND: build
CIBW_BUILD_VERBOSITY: 3
CIBW_TEST_REQUIRES: pytest scipy
diff --git a/.github/workflows/test-linux.yml b/.github/workflows/test-linux.yml
index 0cb36c9..b7de300 100644
--- a/.github/workflows/test-linux.yml
+++ b/.github/workflows/test-linux.yml
@@ -13,7 +13,7 @@ jobs:
strategy:
fail-fast: false
matrix:
- python-version: ["3.10", "3.11", "3.12", "3.13", "3.14", "3.15"]
+ python-version: ["3.10", "3.11", "3.12", "3.13", "3.14", "3.14t", "3.15"]
resolution: ["lowest-direct", "highest"]
exclude:
- python-version: "3.12"
@@ -22,6 +22,8 @@ jobs:
resolution: "lowest-direct"
- python-version: "3.14"
resolution: "lowest-direct"
+ - python-version: "3.14t"
+ resolution: "lowest-direct"
- python-version: "3.15"
resolution: "lowest-direct"
steps:
@@ -43,8 +45,6 @@ jobs:
- name: Install Ubuntu-build dependencies
run: |
- # sudo apt-get update
- # sudo apt-get install -y libopenblas-dev
gfortran --version
gcc --version
diff --git a/README.md b/README.md
index 30c160c..f3369f2 100644
--- a/README.md
+++ b/README.md
@@ -14,9 +14,7 @@ of the original Fortran implementation, while working within the modern Python e
ODR, also known as [errors-in-variables regression], is designed primarily for instances when both
the explanatory and response variables have significant errors.
-
-
-
+
[errors-in-variables regression]: https://en.wikipedia.org/wiki/Errors-in-variables_models
[odrpack95]: https://github.com/HugoMVale/odrpack95
diff --git a/meson.build b/meson.build
index 2010ede..8e66718 100644
--- a/meson.build
+++ b/meson.build
@@ -1,7 +1,7 @@
project(
'odrpack',
['cpp', 'fortran'],
- version : '0.7.0',
+ version : '0.7.1',
meson_version: '>=1.5.0',
default_options: [
'buildtype=release',
@@ -15,6 +15,15 @@ project(
python = import('python').find_installation(pure: false)
python_dep = python.dependency()
+# Free-threaded CPython (3.13t, 3.14t, ...): nanobind -- both the static library
+# and the extension -- must be compiled with NB_FREE_THREADED. Otherwise the
+# module does not declare Py_MOD_GIL_NOT_USED (CPython silently re-enables the
+# GIL on import) and nanobind's internals are not thread-safe. Global arguments
+# are used on purpose, because they also reach the nanobind subproject.
+if python.get_variable('Py_GIL_DISABLED', 0) == 1
+ add_global_arguments('-DNB_FREE_THREADED', language: 'cpp')
+endif
+
# nanobind (from subprojects)
nanobind_dep = dependency('nanobind', static: true)
diff --git a/src/odrpack/__odrpack.py.cpp b/src/odrpack/__odrpack.py.cpp
index 3e143ba..6bde26d 100644
--- a/src/odrpack/__odrpack.py.cpp
+++ b/src/odrpack/__odrpack.py.cpp
@@ -6,6 +6,7 @@
#include
#include
+#include
#include
#include