Jump to solution
Details

The Fix

pip install pydantic==2.9.1

Based on closed pydantic/pydantic issue #10328 · PR/commit linked

Production note: Most teams hit this during upgrades or environment changes. Roll out with a canary and smoke critical endpoints (health, OpenAPI/docs) before 100%.

Open PR/Commit
@@ -139,7 +139,7 @@ jobs: run: | pdm venv create --with-pip --force $PYTHON - pdm install -G testing -G email + pdm install -G testing -G email -G timezone
fix.md
Option A — Upgrade to fixed release\npip install pydantic==2.9.1\nWhen NOT to use: This fix is not suitable for users who require `tzdata` on all platforms.\n\n

Why This Fix Works in Production

  • Trigger: Users on non-Windows systems faced unnecessary installation requirements for timezone data.
  • Mechanism: The `tzdata` dependency was unnecessarily required for all installations of Pydantic
  • Why the fix works: Turns the `tzdata` dependency into an optional dependency group `timezone`, making it conditional for users who need it. (first fixed release: 2.9.1).
Production impact:
  • If left unfixed, the same config can fail only in production (env differences), causing startup failures or partial feature outages.

Why This Breaks in Prod

  • The `tzdata` dependency was unnecessarily required for all installations of Pydantic
  • Production symptom (often without a traceback): Users on non-Windows systems faced unnecessary installation requirements for timezone data.

Proof / Evidence

Discussion

High-signal excerpts from the issue thread (symptoms, repros, edge-cases).

“@jakob-keller, Thanks for the report. Not sure if that qualifies as a bug, but we can certainly consider making this optional! Would very much appreciate…”
@sydney-runkle · 2024-09-05 · source
“OK, I'll give it a shot! Should I follow the polars example then?”
@jakob-keller · 2024-09-05 · source
“Yep, that works. You can treat it like we do for the [email] add-on for email validator.”
@sydney-runkle · 2024-09-05 · source

Failure Signature (Search String)

  • Users on non-Windows systems faced unnecessary installation requirements for timezone data.
Copy-friendly signature
signature.txt
Failure Signature ----------------- Users on non-Windows systems faced unnecessary installation requirements for timezone data.

Error Message

Signature-only (no traceback captured)
error.txt
Error Message ------------- Users on non-Windows systems faced unnecessary installation requirements for timezone data.

Environment

  • Pydantic: 2

What Broke

Users on non-Windows systems faced unnecessary installation requirements for timezone data.

Why It Broke

The `tzdata` dependency was unnecessarily required for all installations of Pydantic

Fix Options (Details)

Option A — Upgrade to fixed release Safe default (recommended)

pip install pydantic==2.9.1

When NOT to use: This fix is not suitable for users who require `tzdata` on all platforms.

Use when you can deploy the upstream fix. It is usually lower-risk than long-lived workarounds.

Fix reference: https://github.com/pydantic/pydantic/pull/10331

First fixed release: 2.9.1

Last verified: 2026-02-09. Validate in your environment.

Get updates

We publish verified fixes weekly. No spam.

Subscribe

When NOT to Use This Fix

  • This fix is not suitable for users who require `tzdata` on all platforms.

Did This Fix Work in Your Case?

Quick signal helps us prioritize which fixes to verify and improve.

Prevention

  • Add a CI check that diffs key outputs after upgrades (OpenAPI schema snapshots, JSON payload shapes, CLI output).
  • Upgrade behind a canary and run integration tests against the canary before 100% rollout.

Version Compatibility Table

VersionStatus
2.9.1 Fixed

Related Issues

No related fixes found.

Sources

We don’t republish the full GitHub discussion text. Use the links above for context.