Add deprecation warning for default output-model-type#2910
Conversation
📝 WalkthroughWalkthroughThe changes add a deprecation warning that alerts users when they don't explicitly specify the Changes
Estimated code review effort🎯 2 (Simple) | ⏱️ ~8 minutes Poem
Pre-merge checks and finishing touches✅ Passed checks (5 passed)
✨ Finishing touches
📜 Recent review detailsConfiguration used: Path: .coderabbit.yaml Review profile: CHILL Plan: Pro 📒 Files selected for processing (2)
🧰 Additional context used🧠 Learnings (3)📓 Common learnings📚 Learning: 2026-01-02T08:25:19.839ZApplied to files:
📚 Learning: 2025-12-25T09:23:08.506ZApplied to files:
🧬 Code graph analysis (1)src/datamodel_code_generator/__main__.py (1)
⏰ 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). (10)
🔇 Additional comments (2)
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. Comment |
|
📚 Docs Preview: https://pr-2910.datamodel-code-generator.pages.dev |
CodSpeed Performance ReportMerging #2910 will not alter performanceComparing
|
Codecov Report✅ All modified and coverable lines are covered by tests. Additional details and impacted files@@ Coverage Diff @@
## main #2910 +/- ##
=======================================
Coverage 99.40% 99.40%
=======================================
Files 95 95
Lines 16903 16905 +2
Branches 1989 1990 +1
=======================================
+ Hits 16802 16804 +2
Misses 52 52
Partials 49 49
Flags with carried forward coverage won't be shown. Click here to find out more. ☔ View full report in Codecov by Sentry. 🚀 New features to boost your workflow:
|
Breaking Change AnalysisResult: No breaking changes detected Reasoning: This PR adds a deprecation warning when --output-model-type is not explicitly specified and defaults to pydantic.BaseModel (Pydantic v1). The warning is purely informational and does not change any behavior, generated code, CLI options, or defaults. Deprecation warnings are not breaking changes - they inform users about future changes but don't require immediate action. Users who already explicitly specify --output-model-type (via CLI or config) won't see any warning. The generated code remains identical whether the warning is shown or not. This analysis was performed by Claude Code Action |
|
🎉 Released in 0.52.1 This PR is now available in the latest release. See the release notes for details. |
Fixes: #2466
Summary by CodeRabbit
✏️ Tip: You can customize this high-level summary in your review settings.