Update version numbers to prepare for v2.1 release#250
Conversation
adf44f6 to
2a462c3
Compare
| * Added support for Python 3.15 and support for C extensions generated by CFFI to target the new ``abi3t`` free-threaded ABI. (`#232`_) | ||
| * Avoid crashes inside of ``__delitem__``. (`#235`_) | ||
| * Avoid "string too big" error under MSVC. (`#167`_) | ||
| * Fix mingw builds. (`#198`_) |
There was a problem hiding this comment.
Do you want to mention the new build tool to support non-setuptools build systems?
There was a problem hiding this comment.
Thanks, of course that's a pretty big new feature!
There was a problem hiding this comment.
There was already a release note but it was in the 2.0 notes. I moved it into the correct section.
| if (f != NULL && f != Py_None) { | ||
| PyFile_WriteString("\nFrom: " _CFFI_MODULE_NAME | ||
| "\ncompiled with cffi version: 2.0.1.dev0" | ||
| "\ncompiled with cffi version: 2.1.0.dev0" |
There was a problem hiding this comment.
Is there a test that this matches the __version_info__?
There was a problem hiding this comment.
And could this use CFFI_VERSION instead?
There was a problem hiding this comment.
It can't easily use CFFI_VERSION without adding a new header, since that define lives at the top of src/c/_cffi_backend.c.
There is a test for this:
$ pytest testing/cffi0/test_version.py
============================================= test session starts =============================================
platform darwin -- Python 3.15.0b3, pytest-9.1.1, pluggy-1.6.0
rootdir: /Users/goldbaum/Documents/cffi
configfile: pyproject.toml
collected 5 items
testing/cffi0/test_version.py ....F [100%]
================================================== FAILURES ===================================================
______________________________________________ test_embedding_h _______________________________________________
def test_embedding_h():
cffi_root = Path(os.path.dirname(__file__)).parent.parent
v = cffi.__version__
p = cffi_root / 'src/cffi/_embedding.h'
content = _read(p)
> assert ('cffi version: %s"' % (v,)) in content
E assert ('cffi version: %s"' % ('2.1.0.dev0',)) in '\n/***** Support code for embedding *****/\n\n#ifdef __cplusplus\nextern "C" {\n#endif\n\n\n#if defined(_WIN32)\n# d...\n#undef cffi_compare_and_swap\n#undef cffi_write_barrier\n#undef cffi_read_barrier\n\n#ifdef __cplusplus\n}\n#endif\n'
testing/cffi0/test_version.py:62: AssertionError
I went ahead and updated the test to make that error message nicer for the next person who needs to do this. See the second-to-last commit.
mattip
left a comment
There was a problem hiding this comment.
LGTM, a few small nits so this is less painful next time.

I also updated a few stray spots referring to Python versions that are no longer supported.
A maintainer will need to create a
release-2.1branch after this is merged.