Skip to content

Add Python 3.13 deprecation warning documentation#2743

Merged
koxudaxi merged 2 commits intomainfrom
docs/python-313-deprecation-warning
Dec 22, 2025
Merged

Add Python 3.13 deprecation warning documentation#2743
koxudaxi merged 2 commits intomainfrom
docs/python-313-deprecation-warning

Conversation

@koxudaxi
Copy link
Copy Markdown
Owner

@koxudaxi koxudaxi commented Dec 22, 2025

Fixes: #2287

Summary by CodeRabbit

  • Documentation
    • Added Python 3.13 deprecation warning guidance and troubleshooting section.
    • Documented three workarounds: upgrade Pydantic to v2, upgrade to >=1.10.18, or use --disable-future-imports flag.

✏️ Tip: You can customize this high-level summary in your review settings.

@coderabbitai
Copy link
Copy Markdown

coderabbitai Bot commented Dec 22, 2025

Warning

Rate limit exceeded

@koxudaxi has exceeded the limit for the number of commits that can be reviewed per hour. Please wait 4 minutes and 57 seconds before requesting another review.

⌛ How to resolve this issue?

After the wait time has elapsed, a review can be triggered using the @coderabbitai review command as a PR comment. Alternatively, push new commits to this PR.

We recommend that you space out your commits to avoid hitting the rate limit.

🚦 How do rate limits work?

CodeRabbit enforces hourly rate limits for each developer per organization.

Our paid plans have higher rate limits than the trial, open-source and free plans. In all cases, we re-allow further reviews after a brief timeout.

Please see our FAQ for further information.

📥 Commits

Reviewing files that changed from the base of the PR and between 6db3c31 and 1ff2688.

📒 Files selected for processing (1)
  • docs/python-version-compatibility.md

Walkthrough

Documentation and test docstring updates add guidance for Python 3.13 deprecation warnings when using from __future__ import annotations with older Pydantic versions, including recommended workarounds and solutions.

Changes

Cohort / File(s) Summary
Documentation updates
docs/cli-reference/typing-customization.md, docs/python-version-compatibility.md
Added Python 3.13 deprecation warning notices and troubleshooting guidance for from __future__ import annotations usage with Pydantic versions. Includes workarounds: upgrade Pydantic to >=1.10.18 or v2, use --disable-future-imports flag, or suppress warnings in pytest. Added note about Python 3.14+ native deferred annotations.
Test docstring updates
tests/main/jsonschema/test_main_jsonschema.py
Added multi-line deprecation warning note to test docstring describing Python 3.13 warnings with from __future__ import annotations and Pydantic v1, with recommended workarounds.

Estimated code review effort

🎯 1 (Trivial) | ⏱️ ~5 minutes

  • Documentation additions are straightforward and non-functional
  • Test docstring update is informational only, no code logic changes

Poem

🐰 A rabbit's note on Python's age,
3.13 turns a troubling page—
Annotations now must gently flow,
With Pydantic's wisdom, we shall know!
Hop forward, friends, with clearer ways. 📚✨

Pre-merge checks and finishing touches

✅ Passed checks (5 passed)
Check name Status Explanation
Description Check ✅ Passed Check skipped - CodeRabbit’s high-level summary is enabled.
Title check ✅ Passed The title 'Add Python 3.13 deprecation warning documentation' accurately summarizes the main change: adding documentation about Python 3.13 deprecation warnings related to forward references and future annotations.
Linked Issues check ✅ Passed The PR addresses issue #2287 by documenting Python 3.13 deprecation warnings with multiple solutions: upgrading Pydantic, using --disable-future-imports flag, and suppressing warnings in pytest configuration.
Out of Scope Changes check ✅ Passed All changes are in-scope: documentation updates to cli-reference and python-version-compatibility files, plus a test docstring note, all directly addressing the Python 3.13 deprecation warning issue.
Docstring Coverage ✅ Passed Docstring coverage is 100.00% which is sufficient. The required threshold is 80.00%.

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands and usage tips.

Copy link
Copy Markdown

@coderabbitai coderabbitai Bot left a comment

Choose a reason for hiding this comment

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

Actionable comments posted: 1

🧹 Nitpick comments (2)
docs/cli-reference/typing-customization.md (1)

667-673: Good clarification of the Python 3.13/Pydantic v1 warning, but adjust strong-style for markdownlint.

The new deprecation note is accurate and ties --disable-future-imports to a concrete Python 3.13 + Pydantic v1<1.10.18 warning scenario. However, markdownlint (MD050) is flagging the bold text at line 667; if you want to satisfy that rule, consider switching to underscore style (e.g. __Python 3.13+ Deprecation Warning:__) or relaxing the rule in your config.

docs/python-version-compatibility.md (1)

334-341: Clarify pytest filterwarnings path for Pydantic v2 users.

The pytest configuration (line 339) specifies the module path pydantic.v1.typing, which is specific to Pydantic v1. Since the troubleshooting section advises upgrading to Pydantic v2 as the primary solution, consider clarifying whether v2 users experience the same warning or noting that this suppress configuration is for v1 only.

You may want to verify whether Pydantic v2 users encounter the same typing._eval_type deprecation warning or if the warning path differs.

📜 Review details

Configuration used: Path: .coderabbit.yaml

Review profile: CHILL

Plan: Pro

📥 Commits

Reviewing files that changed from the base of the PR and between 7aa1c41 and 6db3c31.

📒 Files selected for processing (3)
  • docs/cli-reference/typing-customization.md
  • docs/python-version-compatibility.md
  • tests/main/jsonschema/test_main_jsonschema.py
🧰 Additional context used
🪛 markdownlint-cli2 (0.18.1)
docs/python-version-compatibility.md

316-316: Fenced code blocks should have a language specified

(MD040, fenced-code-language)

docs/cli-reference/typing-customization.md

667-667: Strong style
Expected: underscore; Actual: asterisk

(MD050, strong-style)


667-667: Strong style
Expected: underscore; Actual: asterisk

(MD050, strong-style)

⏰ Context from checks skipped due to timeout of 90000ms. You can increase the timeout in your CodeRabbit configuration to a maximum of 15 minutes (900000ms). (9)
  • GitHub Check: 3.10 on Ubuntu
  • GitHub Check: 3.13 on Windows
  • GitHub Check: 3.10 on Windows
  • GitHub Check: py312-isort5 on Ubuntu
  • GitHub Check: 3.14 on Windows
  • GitHub Check: 3.11 on Windows
  • GitHub Check: 3.12 on Windows
  • GitHub Check: Analyze (python)
  • GitHub Check: benchmarks
🔇 Additional comments (2)
tests/main/jsonschema/test_main_jsonschema.py (1)

141-146: Docstring note is clear and consistent with the PR objective.

The Python 3.13/Pydantic v1 deprecation warning explanation and suggested mitigations are accurate and helpful in this test’s docstring context.

docs/python-version-compatibility.md (1)

312-346: Well-structured troubleshooting guidance addressing the PR objectives.

The new troubleshooting section appropriately documents the Python 3.13 deprecation warning, clearly explains the cause, and provides three practical solutions ordered from best-practice (upgrade) to temporary workarounds. The note about Python 3.14+ native deferred annotations provides helpful context for future compatibility.

Comment thread docs/python-version-compatibility.md
@codecov
Copy link
Copy Markdown

codecov Bot commented Dec 22, 2025

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 99.37%. Comparing base (7aa1c41) to head (1ff2688).
⚠️ Report is 2 commits behind head on main.

Additional details and impacted files
@@           Coverage Diff           @@
##             main    #2743   +/-   ##
=======================================
  Coverage   99.37%   99.37%           
=======================================
  Files          83       83           
  Lines       12233    12233           
  Branches     1467     1467           
=======================================
  Hits        12156    12156           
  Misses         45       45           
  Partials       32       32           
Flag Coverage Δ
unittests 99.37% <ø> (ø)

Flags with carried forward coverage won't be shown. Click here to find out more.

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.

@codspeed-hq
Copy link
Copy Markdown

codspeed-hq Bot commented Dec 22, 2025

CodSpeed Performance Report

Merging #2743 will not alter performance

Comparing docs/python-313-deprecation-warning (1ff2688) with main (7aa1c41)

Summary

✅ 73 untouched
⏩ 10 skipped1

Footnotes

  1. 10 benchmarks were skipped, so the baseline results were used instead. If they were deleted from the codebase, click here and archive them to remove them from the performance reports.

@koxudaxi koxudaxi enabled auto-merge (squash) December 22, 2025 16:42
@koxudaxi koxudaxi merged commit c784c4b into main Dec 22, 2025
34 checks passed
@koxudaxi koxudaxi deleted the docs/python-313-deprecation-warning branch December 22, 2025 16:44
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Python 3.13 deprecates forward references

1 participant