FazBrowse GitHub Viewer | Trending |
URL:
| Home
Tools: [Download Repo ZIP]   [Original HTTPS Page]

gh-121249: remove F/D type codes from table in the struct module by skirpichev · Pull Request #149346 · python/cpython · GitHub

/ cpython Public

gh-121249: remove F/D type codes from table in the struct module - #149346

Merged
vstinner merged 14 commits into
python:mainfrom
skirpichev:struct-deprecate-complex
Jun 26, 2026
Merged

gh-121249: remove F/D type codes from table in the struct module#149346
vstinner merged 14 commits into
python:mainfrom
skirpichev:struct-deprecate-complex

Conversation

skirpichev commented May 4, 2026
edited by bedevere-app Bot
Loading

Copy link
Copy Markdown
Member

read-the-docs-community Bot commented May 4, 2026
edited
Loading

Copy link
Copy Markdown

Comment thread Doc/library/struct.rst Outdated

Copy link
Copy Markdown
Member

What is the reason for deprecation? Also, why is it linked to an issue closed long time ago?

Copy link
Copy Markdown
Member Author

What is the reason for deprecation?

It's an alternative to #148676, see python/steering-council#345 (comment)

There are 3 PRs:

Also, why is it linked to an issue closed long time ago?

Reopened, thanks.

encukou commented May 4, 2026

Copy link
Copy Markdown
Member

I'm -1.

@hugovk any objections to deprecating in a later beta, rather than b1? That would mean we don't need to decide now.

skirpichev closed this May 4, 2026
skirpichev deleted the struct-deprecate-complex branch May 4, 2026 15:09
skirpichev restored the struct-deprecate-complex branch May 5, 2026 02:18
skirpichev reopened this May 5, 2026
skirpichev changed the title gh-121249: deprecate support for complex types in the struct module gh-121249: deprecate support for F/D type codes in the struct module May 5, 2026
skirpichev requested a review from vstinner May 5, 2026 02:41

skirpichev commented May 5, 2026
edited
Loading

Copy link
Copy Markdown
Member Author

I removed F/D types from the table and postponed removal to 3.20. I think it's now along line of using two-letters type codes in the array, ctypes and for memoryvieweverywhere.

CC @vstinner

Edit: Alternatively - we could just drop old type codes from the table (no deprecation).

vstinner commented May 6, 2026

Copy link
Copy Markdown
Member

It's too late to introduce a deprecation in Python 3.15. We can reconsider a deprecation in Python 3.16.

skirpichev changed the title gh-121249: deprecate support for F/D type codes in the struct module gh-121249: remove F/D type codes from table in the struct module May 7, 2026

Copy link
Copy Markdown
Member

I would like to hear the Steering Council opinion on this question.

skirpichev added the needs backport to 3.15 pre-release feature fixes, bugs and security fixes label May 18, 2026

Copy link
Copy Markdown
Member Author

I would like to hear the Steering Council opinion on this question.

@vstinner, what does require SC decision on this? It's regular documentation change, no deprecations.

Copy link
Copy Markdown
Member Author

CC @warsaw as SC voice in python/steering-council#345, per Victor's request.

vstinner commented Jun 3, 2026

Copy link
Copy Markdown
Member

I created the issue python/steering-council#352 for the Steering Council to "Deprecated F and D format in the struct module in Python 3.16".

Copy link
Copy Markdown
Member

Hi, the SC decision is to soft deprecate in Python 3.15 and deprecate in Python 3.16: python/steering-council#352 (comment) Currently, the PR does soft deprecate in Python 3.16.

Do you want to create a Python 3.15 PR to soft deprecate and a Python 3.16 to deprecate?

Copy link
Copy Markdown
Member Author

Currently, the PR does soft deprecate in Python 3.16.

No, it does this for v3.15 entry. I'll add news entry and then this will be ready for a backport.

I'll do a separate pr for v3.16 one something like this (soft-deprecation) will be merged.

Comment thread Doc/deprecations/soft-deprecations.rst Outdated
Comment thread Doc/whatsnew/3.15.rst Outdated

Copy link
Copy Markdown
Member

No, it does this for v3.15 entry. I'll add news entry and then this will be ready for a backport. I'll do a separate pr for v3.16 one something like this (soft-deprecation) will be merged.

I see that the soft deprecation must be documented in What's New In Python 3.15 document which is also part of the main branch, so ok, it makes sense :-)

Co-authored-by: Victor Stinner <vstinner@python.org>

vstinner left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Choose a reason Spam Abuse Off Topic Outdated Duplicate Resolved Low Quality

LGTM

vstinner merged commit 5f17434 into python:main Jun 26, 2026
34 checks passed
github-project-automation Bot moved this from Todo to Done in Docs PRs Jun 26, 2026

Copy link
Copy Markdown

Thanks @skirpichev for the PR, and @vstinner for merging it 🌮🎉.. I'm working now to backport this PR to: 3.15.
🐍🍒⛏🤖

Copy link
Copy Markdown

Sorry, @skirpichev and @vstinner, I could not cleanly backport this to 3.15 due to a conflict.
Please backport using cherry_picker on command line.

cherry_picker 5f17434a1ec9a121eb38f71dc3d5809020b5fbb4 3.15

bedevere-app Bot commented Jun 26, 2026

Copy link
Copy Markdown

GH-152274 is a backport of this pull request to the 3.15 branch.

bedevere-app Bot removed the needs backport to 3.15 pre-release feature fixes, bugs and security fixes label Jun 26, 2026
skirpichev deleted the struct-deprecate-complex branch June 26, 2026 13:36
vstinner added a commit that referenced this pull request Jun 26, 2026
#152274)

gh-121249: Soft deprecate F and D struct format types (#149346)

Remove F/D type codes from table in the struct module documentation.


(cherry picked from commit 5f17434)

Co-authored-by: Sergey B Kirpichev <skirpichev@gmail.com>

Copy link
Copy Markdown
Member

Thanks, I merged your PR to soft deprecate F and D type codes. I'm now waiting for your 3.16 change to (hard) deprecate these type codes :-)

Copy link
Copy Markdown
Member Author

FYI: #152309

This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters. Learn more about bidirectional Unicode characters
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

docs Documentation in the Doc dir skip news

Projects

Status: Done

Development

Successfully merging this pull request may close these issues.

5 participants


Back | FazBrowse Home | New Git URL