Skip to content

Add a default_factory_takes_validated_data property to FieldInfo #11034

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
Dec 3, 2024

Conversation

Viicos
Copy link
Member

@Viicos Viicos commented Dec 3, 2024

Fixes #10945.

Also add a test with model_construct.

Change Summary

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

@github-actions github-actions bot added the relnotes-fix Used for bugfixes. label Dec 3, 2024
Copy link

cloudflare-workers-and-pages bot commented Dec 3, 2024

Deploying pydantic-docs with  Cloudflare Pages  Cloudflare Pages

Latest commit: abfd53d
Status: ✅  Deploy successful!
Preview URL: https://3b989351.pydantic-docs.pages.dev
Branch Preview URL: https://fieldinfo-df.pydantic-docs.pages.dev

View logs

Copy link

codspeed-hq bot commented Dec 3, 2024

CodSpeed Performance Report

Merging #11034 will not alter performance

Comparing fieldinfo-df (abfd53d) with main (aee6057)

Summary

✅ 46 untouched benchmarks

Copy link
Contributor

github-actions bot commented Dec 3, 2024

Coverage report

Click to see where and how coverage changed

FileStatementsMissingCoverageCoverage
(new stmts)
Lines missing
  pydantic
  fields.py
Project Total  

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

Copy link
Contributor

@sydney-runkle sydney-runkle left a comment

Choose a reason for hiding this comment

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

Pretty clean fix, nice work. Thanks!

@sydney-runkle sydney-runkle merged commit 3039e4c into main Dec 3, 2024
54 checks passed
@sydney-runkle sydney-runkle deleted the fieldinfo-df branch December 3, 2024 14:42
@Viicos Viicos added relnotes-feature and removed relnotes-fix Used for bugfixes. labels Jan 29, 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.

2.10: mypy (with pydantic.mypy) complains about Too few arguments on default factory
2 participants
pFad - Phonifier reborn

Pfad - The Proxy pFad of © 2024 Garber Painting. All rights reserved.

Note: This service is not intended for secure transactions such as banking, social media, email, or purchasing. Use at your own risk. We assume no liability whatsoever for broken pages.


Alternative Proxies:

Alternative Proxy

pFad Proxy

pFad v3 Proxy

pFad v4 Proxy