Skip to content
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

feat(Pydantic): added parameters in pydantic plugin to support strict validation and all the model_dump args #3608

Conversation

Copy link

codecov bot commented Jul 3, 2024

Codecov Report

All modified and coverable lines are covered by tests ✅

Project coverage is 98.27%. Comparing base (ec77ce6) to head (7a88082).

Additional details and impacted files
@@            Coverage Diff             @@
##             main    #3608      +/-   ##
==========================================
+ Coverage   98.25%   98.27%   +0.01%     
==========================================
  Files         328      328              
  Lines       14870    14885      +15     
  Branches     2366     2366              
==========================================
+ Hits        14611    14628      +17     
+ Misses        117      116       -1     
+ Partials      142      141       -1     

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

@Anu-cool-007 Anu-cool-007 force-pushed the 3573-add-pydantic-plugin-parameters branch from 0a3bafe to b13c0b8 Compare July 3, 2024 20:53
@Anu-cool-007 Anu-cool-007 changed the title feat(Pydantic): added parameters to pydantic plugin to support strict validation and type include/exclude feat(Pydantic): added parameters in pydantic plugin to support strict validation and include/exclude Jul 3, 2024
@Anu-cool-007 Anu-cool-007 changed the title feat(Pydantic): added parameters in pydantic plugin to support strict validation and include/exclude feat(Pydantic): added parameters in pydantic plugin to support strict validation and all the model_dump args Jul 3, 2024
Copy link
Member

@provinzkraut provinzkraut left a comment

Choose a reason for hiding this comment

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

Thanks @Anu-cool-007!

litestar/contrib/pydantic/__init__.py Outdated Show resolved Hide resolved
@provinzkraut
Copy link
Member

@kedod can you review this one as well?

@Anu-cool-007
Copy link
Contributor Author

@provinzkraut, is there a specific format for docstrings that I should use?

Copy link
Member

@provinzkraut provinzkraut left a comment

Choose a reason for hiding this comment

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

@Anu-cool-007 I went over the docstrings and made some suggestions. Aside from that this is good to go

litestar/contrib/pydantic/__init__.py Outdated Show resolved Hide resolved
litestar/contrib/pydantic/pydantic_init_plugin.py Outdated Show resolved Hide resolved
@Anu-cool-007 Anu-cool-007 force-pushed the 3573-add-pydantic-plugin-parameters branch from b12d731 to 181fc7c Compare July 11, 2024 07:41
@provinzkraut provinzkraut enabled auto-merge (squash) July 11, 2024 07:57
@provinzkraut provinzkraut force-pushed the 3573-add-pydantic-plugin-parameters branch from 181fc7c to 7a88082 Compare July 11, 2024 07:58
Copy link

Documentation preview will be available shortly at https://litestar-org.github.io/litestar-docs-preview/3608

@provinzkraut provinzkraut merged commit 5bcb256 into litestar-org:main Jul 11, 2024
25 checks passed
@Anu-cool-007
Copy link
Contributor Author

@all-contributors add @Anu-cool-007 for code

Copy link
Contributor

@Anu-cool-007

I've put up a pull request to add @Anu-cool-007! 🎉

Alc-Alc pushed a commit that referenced this pull request Jul 26, 2024
… validation and all the `model_dump` args (#3608)

feat: added parameters to pydantic plugin
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
area/types This PR involves changes to the custom types pr/external pr/internal size: small Triage Required 🏥 This requires triage type/feat
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Enhancement: Support configuring Pydantic's .model_validate(..., strict=True)
2 participants