litestar-org / polyfactory

Simple and powerful factories for mock data generation
https://polyfactory.litestar.dev/
MIT License
988 stars 78 forks source link

Enhancement: switch to type-lens #550

Open guacs opened 3 months ago

guacs commented 3 months ago

Summary

We have a lot of utility functions to help us figure out the various types from models and extract information from them. A lot of this is now included in type-lens, so we should be switching to using that instead.

cc: @peterschutt

Basic Example

No response

Drawbacks and Impact

I'm not sure if there's an easy way to do this without making breaking changes. There may be, but I am inclined to make the breaking changes regadlless. I don't think it would effect users too much since most likely it would only change things like FieldModel and some other stuff that polyfactory which, while technically public API, are probably not used by many users.

Unresolved questions

No response


[!NOTE]
While we are open for sponsoring on GitHub Sponsors and OpenCollective, we also utilize Polar.sh to engage in pledge-based sponsorship.

Check out all issues funded or available for funding on our Polar.sh dashboard

  • If you would like to see an issue prioritized, make a pledge towards it!
  • We receive the pledge once the issue is completed & verified
  • This, along with engagement in the community, helps us know which features are a priority to our users.

Fund with Polar