10000 Add support for `defer_build` with `@validate_call` decorator by Viicos · Pull Request #11584 · pydantic/pydantic · GitHub
[go: up one dir, main page]

Skip to content

Add support for defer_build with @validate_call decorator #11584

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 1 commit into from
Mar 20, 2025

Conversation

Viicos
Copy link
Member
@Viicos Viicos commented Mar 19, 2025

Change Summary

Fixes #11582.

All the schema generation logic is moved into a _create_validators() function, logic is identical.

Related issue number

Checklist

  • The pull request title is a good summary of the changes - it will be used in the changelog
  • Unit tests for the changes exist
  • Tests pass on CI
  • Documentation reflects the changes where applicable
  • My PR is ready to review, please add a comment including the phrase "please review" to assign reviewers

@Viicos Viicos requested a review from davidhewitt March 19, 2025 09:42
@github-actions github-actions bot added the relnotes-fix Used for bugfixes. label Mar 19, 2025
Copy link

Deploying pydantic-docs with  Cloudflare Pages  Cloudflare Pages

Latest commit: e21f580
Status: ✅  Deploy successful!
Preview URL: https://f423834d.pydantic-docs.pages.dev
Branch Preview URL: https://validate-call-defer-build.pydantic-docs.pages.dev

View logs

Copy link
codspeed-hq bot commented Mar 19, 2025

CodSpeed Performance Report

Merging #11584 will not alter performance

Comparing validate-call-defer-build (e21f580) with main (a2846da)

Summary

✅ 46 untouched benchmarks

Copy link
Contributor

Coverage report

Click to see where and how coverage changed

FileStatementsMissingCoverageCoverage
(new stmts)
Lines missing
  pydantic/_internal
  _validate_call.py
Project Total  

This report was generated by python-coverage-comment-action

@Viicos Viicos merged commit 8e98bc0 into main Mar 20, 2025
63 checks passed
@Viicos Viicos deleted the validate-call-defer-build branch March 20, 2025 13:38
@Viicos Viicos added relnotes-feature and removed relnotes-fix Used for bugfixes. labels Mar 27, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

validate_call decorator does not work with staticmethod/classmethod that explicitly set return the class itself
2 participants
0