Skip to content

Update pydantic to 2.13.0#515

Merged
jan-janssen merged 2 commits intomainfrom
pydantic
Apr 13, 2026
Merged

Update pydantic to 2.13.0#515
jan-janssen merged 2 commits intomainfrom
pydantic

Conversation

@jan-janssen
Copy link
Copy Markdown
Member

@jan-janssen jan-janssen commented Apr 13, 2026

Summary by CodeRabbit

Chores

  • Updated Pydantic dependency from version 2.12.5 to 2.13.0 across all environment configurations including documentation build, Binder instance, and project dependencies to maintain consistency across development and deployment environments.

Copilot AI review requested due to automatic review settings April 13, 2026 13:40
@coderabbitai
Copy link
Copy Markdown

coderabbitai bot commented Apr 13, 2026

📝 Walkthrough

Walkthrough

Updated the pydantic dependency from version 2.12.5 to 2.13.0 across four configuration files: .ci_support/environment-docs.yml, .ci_support/environment.yml, binder/environment.yml, and pyproject.toml.

Changes

Cohort / File(s) Summary
CI Support Environments
.ci_support/environment-docs.yml, .ci_support/environment.yml
Updated pydantic from 2.12.5 to 2.13.0.
Project Dependencies
pyproject.toml
Updated pydantic optional dependency from 2.12.5 to 2.13.0.
Binder Environment
binder/environment.yml
Added pydantic=2.13.0 to the dependency list.

Estimated code review effort

🎯 1 (Trivial) | ⏱️ ~2 minutes

Suggested labels

dependencies

Poem

🐰 Hop, hop, hooray! A version bump so fine,
Pydantic climbs from point-one-two to thirteen's line,
Across the configs, files aligned with care,
Fresh validation powers floating through the air! ✨

🚥 Pre-merge checks | ✅ 3
✅ Passed checks (3 passed)
Check name Status Explanation
Description Check ✅ Passed Check skipped - CodeRabbit’s high-level summary is enabled.
Title check ✅ Passed The title accurately and clearly describes the main change: updating the pydantic dependency from 2.12.5 to 2.13.0 across multiple configuration files.
Docstring Coverage ✅ Passed No functions found in the changed files to evaluate docstring coverage. Skipping docstring coverage check.

✏️ Tip: You can configure your own custom pre-merge checks in the settings.

✨ Finishing Touches
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Commit unit tests in branch pydantic

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
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

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

Pull request overview

Updates the pinned pydantic dependency version across the project’s packaging metadata and Conda environments to keep optional config validation aligned with the latest supported pydantic release.

Changes:

  • Bump the pydantic optional extra in pyproject.toml from 2.12.5 to 2.13.0.
  • Update CI Conda environments to use pydantic 2.13.0.
  • Add pydantic 2.13.0 to the Binder environment.

Reviewed changes

Copilot reviewed 4 out of 4 changed files in this pull request and generated no comments.

File Description
pyproject.toml Updates the optional pydantic extra pin to 2.13.0.
binder/environment.yml Adds pydantic 2.13.0 to the Binder Conda environment.
.ci_support/environment.yml Updates CI Conda environment pin to pydantic 2.13.0.
.ci_support/environment-docs.yml Updates docs CI Conda environment pin to pydantic 2.13.0.

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

@codecov
Copy link
Copy Markdown

codecov bot commented Apr 13, 2026

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 92.50%. Comparing base (cd4c8b0) to head (5af1789).
⚠️ Report is 1 commits behind head on main.

Additional details and impacted files
@@           Coverage Diff           @@
##             main     #515   +/-   ##
=======================================
  Coverage   92.50%   92.50%           
=======================================
  Files          20       20           
  Lines        1068     1068           
=======================================
  Hits          988      988           
  Misses         80       80           

☔ 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.

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

🤖 Prompt for all review comments with AI agents
Verify each finding against the current code and only fix it if needed.

Inline comments:
In @.ci_support/environment-docs.yml:
- Line 16: The pinned dependency line "pydantic =2.13.0" references a
non-existent final release; change the pin to a valid release specifier—either
explicitly target the latest beta (e.g., "pydantic =2.13.0b3") if you intend a
beta, or switch to a known-stable version (for example "pydantic =2.12.x" or a
specific stable like "pydantic =2.12.5") so package resolution will succeed;
update the dependency string accordingly wherever "pydantic =2.13.0" appears.
🪄 Autofix (Beta)

Fix all unresolved CodeRabbit comments on this PR:

  • Push a commit to this branch (recommended)
  • Create a new PR with the fixes

ℹ️ Review info
⚙️ Run configuration

Configuration used: defaults

Review profile: CHILL

Plan: Pro

Run ID: 9458361c-883e-40df-8517-bda484144286

📥 Commits

Reviewing files that changed from the base of the PR and between cd4c8b0 and 5af1789.

📒 Files selected for processing (4)
  • .ci_support/environment-docs.yml
  • .ci_support/environment.yml
  • binder/environment.yml
  • pyproject.toml

- jupyter-book =1.0.0
- python =3.12
- pydantic =2.12.5
- pydantic =2.13.0
Copy link
Copy Markdown

Choose a reason for hiding this comment

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

⚠️ Potential issue | 🔴 Critical

🧩 Analysis chain

🌐 Web query:

Verify Pydantic 2.13.0 compatibility notes for documentation tooling contexts (import-time behavior, deprecations, or config changes that could affect Sphinx/autodoc builds).

💡 Result:

As of April 13, 2026, the upstream pydantic repo does not show a final v2.13.0 tag—only v2.13.0b1 (Feb 23, 2026), v2.13.0b2 (Feb 24, 2026), and v2.13.0b3 (Mar 31, 2026). [1]

Documentation-tooling–relevant compatibility notes seen in the 2.13.0 beta release notes (i.e., things that can affect Sphinx/autodoc import + signature rendering) include:

  • Reduced eager annotation evaluation during signature/introspection logic: 2.13.0b1 includes “Do not eagerly evaluate annotations in signature logic”, which can change import-time behavior and can prevent failures when annotations reference optional/unavailable imports during autodoc runs. [2]
  • Better diagnostics when using ImportString: 2.13.0b1 notes “Improve ImportString error when internal imports fail”, which can change the exception/warning surface you see in autodoc builds that import modules. [2]
  • Packaging/layout change: 2.13.0b1 states the pydantic-core repository was merged into the main pydantic repo (“Import pydantic-core into pydantic”). This is unlikely to change your runtime imports (pydantic_core is still a dependency), but it can affect how you trace/build/debug native-wheel issues in doc build environments. [2]
  • Backported pydantic.v1 namespace fix (beta): 2.13.0b2 includes “Fix backported V1 namespace”, relevant if autodoc imports pydantic.v1 for legacy docs. [3]

Deprecations/config behaviors that commonly break doc builds (especially when Sphinx is run with -W / “warnings as errors”) still apply in the v2 line (not unique to 2.13), notably:

  • Pydantic v2 retains deprecated APIs that emit DeprecationWarning, and specifically mentions that the v1-style behavior involving an inner Config class on models is deprecated—either of which can fail documentation builds if warnings are treated as errors. [4]

Sources:
[1] Pydantic GitHub tags/releases list showing only 2.13.0 beta tags (no final 2.13.0). (github.com)
[2] Pydantic v2.13.0b1 release notes (signature/annotation evaluation, ImportString error improvements, pydantic-core merge). (github.com)
[3] Pydantic v2.13.0b2 release notes (backported V1 namespace fix). (github.com)
[4] Pydantic migration guide (deprecation warnings; deprecation around Config/config behavior). (pydantic.dev)

Citations:


Pydantic v2.13.0 does not have a final release yet—only beta versions (b1, b2, b3) exist as of April 2026.

Pinning to pydantic =2.13.0 will cause package resolution to fail. As of April 13, 2026, the Pydantic repository shows only beta tags (v2.13.0b1, v2.13.0b2, v2.13.0b3); no final v2.13.0 has been released.

If the intent is to use the latest beta, explicitly pin to a beta version (e.g., =2.13.0b3). Otherwise, use a stable released version or wait for the final v2.13.0 release.

🤖 Prompt for AI Agents
Verify each finding against the current code and only fix it if needed.

In @.ci_support/environment-docs.yml at line 16, The pinned dependency line
"pydantic =2.13.0" references a non-existent final release; change the pin to a
valid release specifier—either explicitly target the latest beta (e.g.,
"pydantic =2.13.0b3") if you intend a beta, or switch to a known-stable version
(for example "pydantic =2.12.x" or a specific stable like "pydantic =2.12.5") so
package resolution will succeed; update the dependency string accordingly
wherever "pydantic =2.13.0" appears.

@jan-janssen jan-janssen merged commit 8fa3f67 into main Apr 13, 2026
31 checks passed
@jan-janssen jan-janssen deleted the pydantic branch April 13, 2026 13: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.

2 participants