From 2486bf7138ede62e1f8ed486557b9c41d870ee13 Mon Sep 17 00:00:00 2001 From: Matt Davis Date: Mon, 28 Jul 2025 12:15:47 -0700 Subject: [PATCH] Release 2.0.0b1 --- doc/source/conf.py | 2 +- doc/source/installation.rst | 4 ++-- doc/source/whatsnew.rst | 9 +++++---- pyproject.toml | 2 +- src/c/_cffi_backend.c | 2 +- src/c/test_c.py | 2 +- src/cffi/__init__.py | 4 ++-- src/cffi/_embedding.h | 2 +- 8 files changed, 14 insertions(+), 13 deletions(-) diff --git a/doc/source/conf.py b/doc/source/conf.py index 54046b96..09a31079 100644 --- a/doc/source/conf.py +++ b/doc/source/conf.py @@ -47,7 +47,7 @@ # The short X.Y version. version = '2.0' # The full version, including alpha/beta/rc tags. -release = '2.0.0.dev0' +release = '2.0.0b1' # The language for content autogenerated by Sphinx. Refer to documentation # for a list of supported languages. diff --git a/doc/source/installation.rst b/doc/source/installation.rst index 8e69b827..9b1cef2c 100644 --- a/doc/source/installation.rst +++ b/doc/source/installation.rst @@ -17,7 +17,7 @@ platform as well as on Windows 32 and 64. (It relies occasionally on libffi, so it depends on libffi being bug-free; this may not be fully the case on some of the more exotic platforms.) -CFFI is tested with CPython 3.8-3.12. +CFFI is tested with CPython 3.9-3.14. The core speed of CFFI is better than ctypes, with import times being either lower if you use the post-1.0 features, or much higher if you @@ -29,7 +29,7 @@ libraries on PyPy. Requirements: -* CPython 3.8+, or PyPy (PyPy 2.0 for the earliest +* CPython 3.9+, or PyPy (PyPy 2.0 for the earliest versions of CFFI; or PyPy 2.6 for CFFI 1.0). * in some cases you need to be able to compile C extension modules. diff --git a/doc/source/whatsnew.rst b/doc/source/whatsnew.rst index f414157f..a8343016 100644 --- a/doc/source/whatsnew.rst +++ b/doc/source/whatsnew.rst @@ -2,15 +2,16 @@ What's New ====================== -v2.0.0.dev0 +v2.0.0b1 ============ -* Added support for free threaded Python. (`#178`_) +* Added support for free threaded CPython (3.14t+ only). (`#178`_) Note that the free-threaded build does not yet support building extensions with the limited API, so you must set py_limited_api=False when building - extensions for the free-threaded build. + extensions for the free-threaded build. CPython 3.13t is not currently supported due to differences in sync + primitive behavior from 3.14t that result in segfaults. * Added support for Python 3.14. (`#177`_) -* WIP +* Dropped support for Python 3.8. .. _`#177`: https://github.com/python-cffi/cffi/pull/177 .. _`#178`: https://github.com/python-cffi/cffi/pull/178 diff --git a/pyproject.toml b/pyproject.toml index 07584951..e459b976 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -8,7 +8,7 @@ build-backend = "setuptools.build_meta" [project] name = "cffi" -version = "2.0.0.dev0" +version = "2.0.0b1" dependencies = [ "pycparser; implementation_name != 'PyPy'", ] diff --git a/src/c/_cffi_backend.c b/src/c/_cffi_backend.c index 355a18a7..d2913800 100644 --- a/src/c/_cffi_backend.c +++ b/src/c/_cffi_backend.c @@ -2,7 +2,7 @@ #include #include "structmember.h" #include "misc_thread_common.h" -#define CFFI_VERSION "2.0.0.dev0" +#define CFFI_VERSION "2.0.0b1" #ifdef MS_WIN32 #include diff --git a/src/c/test_c.py b/src/c/test_c.py index 1ba62c21..d70306c2 100644 --- a/src/c/test_c.py +++ b/src/c/test_c.py @@ -63,7 +63,7 @@ def _capture_unraisable_hook(ur_args): # ____________________________________________________________ import sys -assert __version__ == "2.0.0.dev0", ("This test_c.py file is for testing a version" +assert __version__ == "2.0.0b1", ("This test_c.py file is for testing a version" " of cffi that differs from the one that we" " get from 'import _cffi_backend'") if sys.version_info < (3,): diff --git a/src/cffi/__init__.py b/src/cffi/__init__.py index 752496d4..48e5be51 100644 --- a/src/cffi/__init__.py +++ b/src/cffi/__init__.py @@ -5,8 +5,8 @@ from .error import CDefError, FFIError, VerificationError, VerificationMissing from .error import PkgConfigError -__version__ = "2.0.0.dev0" -__version_info__ = (2, 0, 0, 'dev0') +__version__ = "2.0.0b1" +__version_info__ = (2, 0, 0, 'b1') # The verifier module file names are based on the CRC32 of a string that # contains the following version number. It may be older than __version__ diff --git a/src/cffi/_embedding.h b/src/cffi/_embedding.h index 2ac957c8..48e5cbfa 100644 --- a/src/cffi/_embedding.h +++ b/src/cffi/_embedding.h @@ -225,7 +225,7 @@ static int _cffi_initialize_python(void) if (f != NULL && f != Py_None) { PyFile_WriteString("\nFrom: " _CFFI_MODULE_NAME - "\ncompiled with cffi version: 2.0.0.dev0" + "\ncompiled with cffi version: 2.0.0b1" "\n_cffi_backend module: ", f); modules = PyImport_GetModuleDict(); mod = PyDict_GetItemString(modules, "_cffi_backend");