Comparison
factory-boy vs polyfactory vs pydantic-factories
Maintenance, adoption and momentum side by side, from PyPI, GitHub and deps.dev data refreshed every day.
A versatile test fixtures replacement based on thoughtbot's factory_bot for Ruby.
Low maintenance activity. Last release 22 months ago, commits in 0 of the last 26 weeks. Weaker on commit activity and recent releases.
$
pip install factory-boyMock data generation factories
Actively maintained. Last release 6 weeks ago, commits in 10 of the last 26 weeks. A safe choice.
$
pip install polyfactoryMock data generation for pydantic based models and python dataclasses
Archived. The repository is read-only: no more fixes or releases will come.
$
pip install pydantic-factoriesIn short
- pydantic-factories is archived: avoid it for new projects.
- factory-boy is the most used: 24.6M downloads a month, 1.9× more than polyfactory.
- polyfactory is better maintained: Pythie’s Index 76 against 27.
Side by side
| Metric | factory-boy | polyfactory | pydantic-factories |
|---|---|---|---|
| Pythie’s Index | Pythie’s Index: 27 | 76 |