Skip to content
Merged
Show file tree
Hide file tree
Changes from 1 commit
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
Prev Previous commit
Next Next commit
Apply suggestions from code review
Co-authored-by: Victor Stinner <vstinner@python.org>
  • Loading branch information
skirpichev and vstinner authored Jun 30, 2026
commit 87d0ea726185f438dcf07ac1776eafb043c580c3
2 changes: 1 addition & 1 deletion Doc/deprecations/pending-removal-in-3.21.rst
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,6 @@ Pending removal in Python 3.21

* :mod:`struct`:

* Soft-deprecated since Python 3.15 using ``'F'`` and ``'D'`` type codes now
* Soft-deprecated since Python 3.15, using ``'F'`` and ``'D'`` type codes are now
deprecated. These codes will be removed in Python 3.21. Use instead
two-letter forms ``'Zf'`` and ``'Zd'``.
2 changes: 1 addition & 1 deletion Doc/whatsnew/3.16.rst
Original file line number Diff line number Diff line change
Expand Up @@ -487,7 +487,7 @@ New deprecations

* :mod:`struct`:

* Soft-deprecated since Python 3.15 using ``'F'`` and ``'D'`` type codes now
* Soft-deprecated since Python 3.15, using ``'F'`` and ``'D'`` type codes are now
deprecated. These codes will be removed in Python 3.21. Use instead
Comment thread
skirpichev marked this conversation as resolved.
two-letter forms ``'Zf'`` and ``'Zd'``.
(Contributed by Sergey B Kirpichev in :gh:`121249`.)
Expand Down
1 change: 1 addition & 0 deletions Lib/test/test_struct.py
Original file line number Diff line number Diff line change
Expand Up @@ -1009,6 +1009,7 @@ def test_c_complex_round_trip(self):
with warnings.catch_warnings():
with self.assertWarns(DeprecationWarning):
b = struct.pack(f, z)

with warnings.catch_warnings():
warnings.simplefilter("error", DeprecationWarning)
self.assertRaises(DeprecationWarning, struct.unpack, f, b)
Expand Down
Original file line number Diff line number Diff line change
@@ -1 +1 @@
Deprecate using ``'F'`` and ``'D'`` type codes in the :mod:`struct`.
Deprecate using ``'F'`` and ``'D'`` type codes in the :mod:`struct` module.
Loading