Contents

polyfactory 2.17.0

0

Mock data generation factories

Mock data generation factories

Stars: 1027, Watchers: 1027, Forks: 81, Open Issues: 27

The litestar-org/polyfactory repo was created 2 years ago and the last code push was 3 weeks ago.
The project is very popular with an impressive 1027 github stars!

How to Install polyfactory

You can install polyfactory using pip

pip install polyfactory

or add it to a project with poetry

poetry add polyfactory

Package Details

Author
None
License
MIT
Homepage
None
PyPi:
https://pypi.org/project/polyfactory/
GitHub Repo:
https://github.com/litestar-org/polyfactory

Classifiers

  • Software Development
  • Software Development/Libraries
  • Software Development/Testing
  • Software Development/Testing/Unit
  • Utilities
No  polyfactory  pypi packages just yet.

Errors

A list of common polyfactory errors.

Code Examples

Here are some polyfactory code examples and snippets.

GitHub Issues

The polyfactory package has 27 open issues on GitHub

  • feat(factory): switch to using faker.seed_instance
  • Enhancement: switch to using faker.seed_instance
  • Bug: pydantic min_length and max_length are not provided in get_constrained_field_value
  • Bug: Pydantic Json type is disregarded when creating mock data
  • using_base_factories context manager
  • Drop __set_as_default_factory_for_type__
  • Sqlalchemy factory
  • Add sqlalchemy factory
  • Enhancement: use coverage combine
  • Generation not following the constraints when validator is specified
  • Enhancement: Add AttrsFactory
  • Bug: Infinite recursion error with discriminated unions
  • Enhancement: Add a rejection sampler
  • Enhancement: Add SQLModelFactory
  • Bug: When setting size=0, 1 instance is created and not put in a list

See more issues on GitHub

Related Packages & Articles

pydantic-gen generates pydantic schemas from YAML files

pydantic-gen is a code generation python package that takes a YML file containing a OpenAPI Schema and generates python pydantic models. pydantic-gen can get used in your codebase to dynamically regenerate your pydantic models or it can be used one time to generator python code. The author of the pydantic-gen module is Mikhail Beliansky.

authx 1.3.1

Ready to use and customizable Authentications and Oauth2 management for FastAPI

odmantic 1.0.2

ODMantic, an AsyncIO MongoDB Object Document Mapper for Python using type hints

opyrator 0.0.12

Turn python functions into microservices with auto-generated HTTP API, interactive UI, and more.

sqlmodel 0.0.22

SQLModel, SQL databases in Python, designed for simplicity, compatibility, and robustness.