@@ -25,18 +25,29 @@ New Features:
25
25
and ``std::enable_shared_from_this ``.
26
26
`#5542 <https://github.com/pybind/pybind11/pull/5542 >`_
27
27
28
- * Remove support for pybind11 v2 internals versions (4, 5, 6).
29
- (The internals version number has been bumped for pybind11 v3.)
30
- `#5512 <https://github.com/pybind/pybind11/pull/5512 >`_ |
31
- `#5530 <https://github.com/pybind/pybind11/pull/5530 >`_
32
-
33
- * (CMake) Enable FindPython mode by default, with a ``COMPAT `` mode that sets some of the old variables to ease transition.
28
+ * Support for sub-interpreters (both isolated (with separate GILs) and legacy
29
+ (with a global GIL). Add the
30
+ ``py::multiple_interpreters::per_interpreter_gil() `` tag (or,
31
+ ``py::multiple_interpreters::shared_gil() `` for legacy interpreter support)
32
+ to ``PYBIND11_MODULE `` calls (as the third parameter) to indicate that a
33
+ module supports running with sub-interpreters.
34
+ `#5564 <https://github.com/pybind/pybind11/pull/5564 >`_
35
+
36
+ * (CMake) Enable FindPython mode by default, with a ``COMPAT `` mode that sets
37
+ some of the old variables to ease transition.
34
38
`#5553 <https://github.com/pybind/pybind11/pull/5553 >`_
35
39
36
40
* ``py::native_enum `` was added, for conversions between Python's native (stdlib) enum types and C++ enums.
37
41
`#5555 <https://github.com/pybind/pybind11/pull/5555 >`_
38
42
39
- * A ``py::release_gil_before_calling_cpp_dtor `` option (for ``py::class_ ``) was added to resolve the long-standing issue #1446.
43
+ * Add class doc string to ``py::native_enum ``.
44
+ `#5617 <https://github.com/pybind/pybind11/pull/5617 >`_.
45
+
46
+ * Fix signature for functions with a native_enum in the signature.
47
+ `#5619 <https://github.com/pybind/pybind11/pull/5619 >`_
48
+
49
+ * A ``py::release_gil_before_calling_cpp_dtor `` option (for ``py::class_ ``) was
50
+ added to resolve the long-standing issue #1446.
40
51
`#5522 <https://github.com/pybind/pybind11/pull/5522 >`_
41
52
42
53
* Add ``dtype::normalized_num `` and ``dtype::num_of ``.
@@ -45,7 +56,9 @@ New Features:
45
56
* Add support for ``array_t<handle> `` and ``array_t<object> ``.
46
57
`#5427 <https://github.com/pybind/pybind11/pull/5427 >`_
47
58
48
- * Added ``py::warnings `` namespace with ``py::warnings::warn `` and ``py::warnings::new_warning_type `` that provides the interface for Python warnings.
59
+ * Added ``py::warnings `` namespace with ``py::warnings::warn `` and
60
+ ``py::warnings::new_warning_type `` that provides the interface for Python
61
+ warnings.
49
62
`#5291 <https://github.com/pybind/pybind11/pull/5291 >`_
50
63
51
64
* stl.h ``list|set|map_caster `` were made more user friendly: it is no longer
@@ -56,10 +69,13 @@ New Features:
56
69
* The ``array_caster `` in pybind11/stl.h was enhanced to support value types that are not default-constructible.
57
70
`#5305 <https://github.com/pybind/pybind11/pull/5305 >`_
58
71
59
- * ``pybind11/conduit/pybind11_platform_abi_id.h `` was factored out, to maximize reusability of ``PYBIND11_PLATFORM_ABI_ID `` (for other Python/C++ binding systems).
72
+ * ``pybind11/conduit/pybind11_platform_abi_id.h `` was factored out, to maximize
73
+ reusability of ``PYBIND11_PLATFORM_ABI_ID `` (for other Python/C++ binding
74
+ systems).
60
75
`#5375 <https://github.com/pybind/pybind11/pull/5375 >`_
61
76
62
- * Changed ``PYBIND11_MODULE `` macro implementation to perform multi-phase module initialization (PEP 489) behind the scenes.
77
+ * Changed ``PYBIND11_MODULE `` macro implementation to perform multi-phase
78
+ module initialization (PEP 489) behind the scenes.
63
79
`#5574 <https://github.com/pybind/pybind11/pull/5574 >`_
64
80
65
81
* Added support for finding pybind11 using pkgconf distributed on pypi.
@@ -93,7 +109,8 @@ New Features (typing):
93
109
* Add ``attr_with_type `` for declaring attribute types and ``Final ``, ``ClassVar `` type annotations.
94
110
`#5460 <https://github.com/pybind/pybind11/pull/5460 >`_
95
111
96
- * Allow annotate methods with ``py::pos_only `` when only have the ``self `` argument. Make arguments for auto-generated dunder methods positional-only.
112
+ * Allow annotate methods with ``py::pos_only `` when only have the ``self ``
113
+ argument. Make arguments for auto-generated dunder methods positional-only.
97
114
`#5403 <https://github.com/pybind/pybind11/pull/5403 >`_
98
115
99
116
* Added ``py::Args `` and ``py::KWArgs `` to enable custom type hinting of ``*args `` and ``**kwargs `` (see PEP 484).
@@ -110,11 +127,34 @@ New Features (typing):
110
127
* Fix module type hint.
111
128
`#5469 <https://github.com/pybind/pybind11/pull/5469 >`_
112
129
130
+ * Fix Buffer type hint.
131
+ `#5662 <https://github.com/pybind/pybind11/pull/5662 >`_
132
+
133
+ * Added support for ``collections.abc `` in type hints and convertible checks of STL casters and ``py::buffer ``.
134
+ `#5566 <https://github.com/pybind/pybind11/pull/5566 >`_
135
+
136
+
137
+ Removals:
138
+
139
+ * Remove support for pybind11 v2 internals versions (4, 5, 6).
140
+ (The internals version number has been bumped for pybind11 v3.)
141
+ `#5512 <https://github.com/pybind/pybind11/pull/5512 >`_ |
142
+ `#5530 <https://github.com/pybind/pybind11/pull/5530 >`_
143
+
144
+
145
+ * Remove ``make_simple_namespace `` (added in 2.8.0, deprecated in 2.8.1).
146
+ `#5597 <https://github.com/pybind/pybind11/pull/5597 >`_
147
+
148
+ * Legacy-mode option ``PYBIND11_NUMPY_1_ONLY `` has been removed.
149
+ `#5595 <https://github.com/pybind/pybind11/pull/5595 >`_
150
+
151
+ * Add a deprecation warning to ``.get_type `` (deprecated in pybind11 2.6 in 2020).
152
+ `#5596 <https://github.com/pybind/pybind11/pull/5596 >`_
113
153
114
154
Bug fixes:
115
155
116
156
* Set ``__file__ `` on submodules.
117
- `#5584 <https://github.com/pybind/pybind11/pull/5584 >`_
157
+ `#5584 <https://github.com/pybind/pybind11/pull/5584 >`_. Except on embedded modules. ` #5650 < https://github.com/pybind/pybind11/pull/5650 >`_
118
158
119
159
* pybind11-bound functions are now pickleable.
120
160
`#5580 <https://github.com/pybind/pybind11/pull/5580 >`_
@@ -156,6 +196,19 @@ Bug fixes:
156
196
* Properly translate C++ exception to Python exception when creating Python buffer from wrapped object.
157
197
`#5324 <https://github.com/pybind/pybind11/pull/5324 >`_
158
198
199
+ * Update the dict when restoring pickles, instead of assigning a replacement dict.
200
+ `#5658 <https://github.com/pybind/pybind11/pull/5658 >`_
201
+
202
+ * Properly define ``_DEBUG `` macro to ``1 `` instead of defining it without value.
203
+ `#5639 <https://github.com/pybind/pybind11/pull/5639 >`_
204
+
205
+ * Fix a missing time cast causing a compile error for newer ICC.
206
+ `#5621 <https://github.com/pybind/pybind11/pull/5621 >`_
207
+
208
+ * Change the behavior of the default constructor of ``py::slice `` to be equivalent to ``:: `` in Python.
209
+ `#5620 <https://github.com/pybind/pybind11/pull/5620 >`_
210
+
211
+
159
212
160
213
.. fix(cmake)
161
214
@@ -170,6 +223,15 @@ Bug fixes (CMake):
170
223
* Fix an issue with ``NO_EXTRAS `` adding ``pybind11::windows_extras `` anyway.
171
224
`#5378 <https://github.com/pybind/pybind11/pull/5378 >`_
172
225
226
+ * Fix issue with NEW/OLD message showing up.
227
+ `#5656 <https://github.com/pybind/pybind11/pull/5656 >`_
228
+
229
+ * Use CMake's warnings as errors if available (CMake 3.24+).
230
+ `#5612 <https://github.com/pybind/pybind11/pull/5612 >`_
231
+
232
+ * Add support for running pybind11's tests via presets in CMake 3.25+.
233
+ `#5655 <https://github.com/pybind/pybind11/pull/5655 >`_
234
+
173
235
174
236
Bug fixes (free-threading):
175
237
@@ -184,6 +246,15 @@ Bug fixes (free-threading):
184
246
* Added exception translator specific mutex used with ``try_translate_exceptions `` in the free-threaded build for internal locking.
185
247
`#5362 <https://github.com/pybind/pybind11/pull/5362 >`_
186
248
249
+ Internals:
250
+
251
+ * Consolidated all ``PYBIND11_HAS_... `` feature macros into ``pybind11/detail/common.h `` to streamline backward compatibility checks and simplify internal refactoring. This change ensures
252
+ consistent macro availability regardless of header inclusion order.
253
+ `#5647 <https://github.com/pybind/pybind11/pull/5647 >`_
254
+
255
+ * ``pybind11/gil_simple.h `` was factored out from ``pybind11/gil.h ``, so that it can easily be reused.
256
+ `#5614 <https://github.com/pybind/pybind11/pull/5614 >`_
257
+
187
258
188
259
Documentation:
189
260
@@ -196,6 +267,8 @@ Documentation:
196
267
* Adds an answer (FAQ) for "What is a highly conclusive and simple way to find memory leaks?".
197
268
`#5340 <https://github.com/pybind/pybind11/pull/5340 >`_
198
269
270
+ * Add documenting for free-threading and subinterpreters.
271
+ `#5659 <https://github.com/pybind/pybind11/pull/5659 >`_
199
272
200
273
Tests:
201
274
@@ -209,9 +282,16 @@ compiling using ``clang`` on Linux with the ``-funsigned-char`` flag.
209
282
* Test PyPy3.11 in CI.
210
283
`#5534 <https://github.com/pybind/pybind11/pull/5534 >`_
211
284
285
+ * CI testing now includes ``-Wwrite-strings -Wunreachable-code -Wpointer-arith -Wredundant-decls `` in some jobs.
286
+ `#5523 <https://github.com/pybind/pybind11/pull/5523 >`_
287
+
212
288
213
289
New and removed platforms:
214
290
291
+
292
+ * Support Python 3.14 (beta 1).
293
+ `#5646 <https://github.com/pybind/pybind11/pull/5646 >`_
294
+
215
295
* Added support for GraalPy Python implementation (https://github.com/oracle/graalpython).
216
296
`#5380 <https://github.com/pybind/pybind11/pull/5380 >`_
217
297
@@ -224,10 +304,11 @@ New and removed platforms:
224
304
* Support for Python 3.7 was removed. (Official end-of-life: 2023-06-27).
225
305
`#5191 <https://github.com/pybind/pybind11/pull/5191 >`_
226
306
227
- * Support for CMake older than 3.15 removed. CMake 3.15-3.30 supported.
307
+ * Support for CMake older than 3.15 removed. CMake 3.15-4.0 supported.
228
308
`#5304 <https://github.com/pybind/pybind11/pull/5304 >`_
229
309
230
-
310
+ * Use scikit-build-core for the build backend for the PyPI ``pybind11 ``. The CMake generation has been moved to the sdist->wheel step. ``PYBIND11_GLOBAL_PREFIX `` has been removed.
311
+ `#5598 <https://github.com/pybind/pybind11/pull/5598 >`_
231
312
232
313
Version 2.13.6 (September 13, 2024)
233
314
-----------------------------------
0 commit comments