Releases: litestar-org/polyfactory
v2.16.0
Sponsors 🌟
Thanks to these incredible business sponsors:
Scalar (@scalar), Telemetry Sports (via @chris-telemetry), Stok (@stok-team)
A huge 'Thank you!' to all other sponsors across Polar.sh, OpenCollective and GitHub Sponsors!
What's Changed
New Contributors
- @wangxin688 made their first contribution in #530
- @impaktor made their first contribution in #537
Fixes 🔧
- Ignore non-columns types by @adhtruong in #510
- Favour SA mapped type over impl type by @adhtruong in #513
- Update typing by @adhtruong in #540
- Fix json type error and pg dialect default value by @wangxin688 in #542
New Features 🚀
- Support nested type in pg.array types and others by @wangxin688 in #530
- Refresh object in async_session after commit to db by @wangxin688 in #541
- Copy mutable args by @adhtruong in #529
Docs 📚
- Apply organization theme by @JacobCoffee in #533
- Update Polyfactory landing page by @JacobCoffee in #535
- Update changelog.rst by @impaktor in #537
Infra 🚆
- Add codecov coverage, fix badges by @JacobCoffee in #536
Full Changelog: v2.15.0...v2.16.0
v2.15.0
❤️ Sponsors ❤️
GitHub Sponsors: Scalar, Telemetry Sports (via @chris-telemetry), Stok (https://github.com/stok-team), @benjamin-kirkbride, @crisog, @geeshta, @cbscsm
OpenCollective: Christian Y, Anonymous
What's Changed
Fixes 🔧
- fix: prefer
sqlalchemy.type.impl
if it exists by @cofin in #502 - fix: constrained unions by @guacs in #499
New Features 🚀
Docs 📚
New Contributors
Full Changelog: v2.14.1...v2.15.0
v2.14.1
❤️ Sponsors ❤️
GitHub Sponsors: Scalar, Telemetry Sports (via @chris-telemetry), Stok (https://github.com/stok-team), @benjamin-kirkbride, @crisog, @geeshta, @cbscsm
OpenCollective: Christian Y, Anonymous
What's Changed
Fixes 🔧
Full Changelog: v2.14.0...v2.14.1
v2.14.0
❤️ Sponsors ❤️
GitHub Sponsors: Scalar, Telemetry Sports (via @chris-telemetry), Stok (@stok-team), @benjamin-kirkbride, @crisog, @geeshta, @cbscsm
OpenCollective: Christian Y, Anonymous
What's Changed
New Features 🚀
- Use the default value if available and
__use_default__
is set toTrue
by @guacs in #472 - Add support for recursive models by @adhtruong in #468
- Add support for Python 3.12 type alias syntax by @adhtruong in #487
Fixes 🔧
- Pin
typing-extensions
to a minimum version of 4.6.0 by @hsorsky in #471 - Set as default type for factory only if model is defined by @guacs in #479
- Properly pass factory configurations to child factories by @adhtruong in #483
Docs 📚
Infra 🚆
- Update pre commit hooks versions by @guacs in #478
- Bump actions/cache from 3 to 4 by @dependabot in #488
New Contributors
Full Changelog: v2.13.0...v2.14.0
v2.13.0
❤️ Sponsors ❤️
GitHub Sponsors: Scalar, Telemetry Sports (via @chris-telemetry) @benjamin-kirkbride @crisog @geeshta
OpenCollective: Christian Y, Anonymous
What's Changed
New Features 🚀
Fixes 🔧
- Handle Optional types in
flatten_annotation
by @sam-or in #440 - Don't blindly suppress ValueError by @guacs in #450
New Contributors
Full Changelog: v2.12.0...v2.13.0
v2.12.0
❤️ Sponsors ❤️
GitHub Sponsors: Telemetry Sports (via @chris-telemetry) @benjamin-kirkbride @crisog @geeshta
OpenCollective: Christian Y, Anonymous
What's Changed
New Features 🚀
- Set
factory.__model__
as default formodel
argument increate_factory
by @g0di in #429 - Model type coverage generation by @sam-or in #390
Fixes 🔧
- Handle cases where 'init=False' for dataclasses and attrs models by @guacs in #433
- Correctly handle collections with constrained items by @guacs in #436
New Contributors
Full Changelog: v2.11.0...v2.12.0
v2.11.0
💰 Sponsors 💰
GitHub Sponsors: @benjamin-kirkbride @crisog
OpenCollective: Christian Y, Anonymous
What's Changed
New Features 🚀
- Check if fields declared on the factory belong to the model by @johnraz in #405
- Support annotation with
Constraints
by @guacs in #411 - Deprecate
FieldMeta
collection params by @adhtruong in #417
Fixes 🔧
- Handle
Required
andNonRequired
annotations inTypedDict
by @guacs in #422 - Respect override of optional nested model fields through
kwargs
passed to thebuild
method by @julioolvr in #420
Infra 🚆
- Update installation of dependencies for document generation by @adhtruong in #414
Documentation 📚
- Reorder documentation and add documentation on factories as fields by @adhtruong in #418
New Contributors
- @johnraz made their first contribution in #405
- @julioolvr made their first contribution in #420
Full Changelog: v2.10.0...v2.11.0
v2.10.0
💰 Sponsors 💰
GitHub Sponsors: @benjamin-kirkbride @crisog
OpenCollective: Christian Y, Anonymous
What's Changed
New Features 🚀
- Support SQLA14 by @adhtruong in #385
Fixes 🔧
- Properly resolve dataclass forward references by @guacs in #383
- Fix alternative version installation by @adhtruong in #389
- Decouple the handling of collection length configuration from
FieldMeta
by @guacs in #407 - Move creation of pydantic provider map by @guacs in #396
- Refactor the msgspec factory to use the fields API by @guacs in #409
Infra 🚆
- Install all dependencies for docs build by @adhtruong in #404
- Update makefile by @JacobCoffee in #399
- Migrate to pdm and full ruff by @JacobCoffee in #384
Full Changelog: v2.9.0...v2.10.0
v2.9.0
🎉 New Contributors 🎉
- @anthonyjgraff made their first contribution in #371
💰 Sponsors 💰
GitHub Sponsors: @benjamin-kirkbride, @crisog
OpenCollective: Christian Y, GitHub Sponsors, Shubham Prajapati, Snyk, Matteo
What's Changed
New Features 🚀
- Implement
sqlalchemy
factory by @adhtruong in #369
🔧 Fixes
- Properly type hint create_factory by @guacs in #360
- Properly handle stringified/forward annotations in
attrs
models by @guacs in #370 - Don't register
AttrsFactory
by default inattrs
models by @guacs in #370 - Handle
size=0
constraints for collections by @adhtruong in #373 - Use
dataclasses
API for parsingdataclass
models by @anthonyjgraff in #371
Infra 🚆
- Make
pytest
configuration stricter by @sobolevn in #363 - Enable publishing with PyPI trusted publishers by @provinzkraut in #368
- Skip variable length dict test for odmantic by @guacs in #372
- Ignore .all-contributorsrc for in .pre-commit by @adhtruong in #377
Full Changelog: v2.8.2...v2.9.0
v2.8.2
🎉 New Contributors 🎉
💰 Sponsors 💰
GitHub Sponsors: @benjamin-kirkbride, @crisog
OpenCollective: Christian Y, GitHub Sponsors, Shubham Prajapati, Snyk
What's Changed
🔧 Fixes
- fix: properly set annotation in union with Annotated constraints in subtypes by @guacs in #355
- fix: add minimum version constraint to attrs by @guacs in #359
📚 Documentation
Full Changelog: v2.8.1...v2.8.2