Skip to content

[Python 3.11 only] "Post-init processing" section of dataclasses contains duplicate sentences + malformatted code example #126462

@akabraham

Description

@akabraham

Documentation

NOTE: Python 3.11 Docs Only

Issue:

The "Post-init processing" section of dataclasses in the Python 3.11 documentation contains duplicate sentences and a malformed code example. These issues aren't in the other active Python versions (i.e. 3.9, 3.10, 3.12, 3.13)

Proposed Fix:

The fix is to replace the 3.11 "Post-init processing" section with that of the 3.12 branch, which doesn't contain the duplicate sentences or bad formatting. To my knowledge, there are no new features added in 3.12 that makes this section incompatible with the 3.11 documentation, so it's safe to use it.

Screenshot of malformatted section in Python 3.11 documentation:
bug_python_3-11_dataclasses_postinit_processing

Screenshot of good section in Python 3.12 documentation:
fixed_python_3-12_dataclasses_postinit_processing

Linked PRs

Metadata

Metadata

Assignees

No one assigned

    Labels

    Projects

    Status

    Todo

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions