skillfed

model-mommy

Smart object creation facility for Django.

model-mommy v2.0.0 339.4K downloads/30d#7,426 on PyPI897
Permissive license Apache 2.0 Abandoned released

What it is and what it does

Model Mommy is a Django testing utility that automatically generates model instances populated with random data, eliminating the need to manually specify every field when creating test fixtures. It introspects Django models and fills in required fields intelligently, making it faster to write test setup code.

However, the package has been abandoned since October 2019 and is no longer maintained. The creators explicitly recommend migrating to Model Bakery, a renamed successor that continues development. While Model Mommy remains functional for legacy projects, new projects should use Model Bakery instead to ensure ongoing support and compatibility with current Django versions.

Use it for:

  • Quickly populate test databases with realistic Django model instances without writing repetitive fixture code.
  • Generate related model objects automatically during unit tests to reduce boilerplate in test setup methods.
  • Create temporary test data with random values to verify model behavior across different field combinations.

Worth the install?

AI-flagged interpretation of the facts on this page — verify before relying

Model Mommy generates Django model instances with random data for testing, automating the creation of test fixtures without manual field specification.

No. Model Mommy is abandoned and explicitly recommends migration to Model Bakery. While it may still work in legacy projects, new projects should use Model Bakery instead. Existing projects should plan migration to maintain compatibility with future Django versions and receive security updates.

Install

model-mommy on PyPI

pip

pip install model-mommy

uv

uv add model-mommy

poetry

poetry add model-mommy

Installing model-mommy

Before you install

Installation is straightforward with low friction, but the package is abandoned as of 2019-10-21 and explicitly recommends migration to Model Bakery. No active maintenance or security updates are available.

License in practice

Licensed under Apache 2.0 (permissive), allowing commercial and private use with minimal restrictions, though the abandoned status means no legal updates or clarifications will be issued.

Quickstart

pip install model-mommy
from model_mommy import mommy
user = mommy.make('myapp.User')

Requires Django to be installed; package is no longer maintained and its creators recommend migrating to Model Bakery instead.

Verify before relying

  • Whether existing projects using model-mommy encounter compatibility issues with modern Django versions beyond 2.x
  • Whether the single runtime dependency (django) has specific version constraints that the fact sheet does not specify

Package facts

License Apache 2.0 (permissive)
Python support not specified
Install friction low — pure-Python wheel
Runtime dependencies 1 — django
Maintenance abandoned — 2,489 days since the last release
Last repo commit (repository archived)
First released
Downloads 339,390/month — #7,426 on PyPI (30-day window, as of 2026-08-14)
Known vulnerabilities none known (OSV.dev, checked 2026-08-14)

Evidence: model_mommy-2.0.0-py2.py3-none-any.whl

Keywords: django, testing, factory, python

Framework :: DjangoIntended Audience :: DevelopersLicense :: OSI Approved :: Apache Software LicenseOperating System :: OS IndependentProgramming Language :: Python :: 3.5Programming Language :: Python :: 3.6Topic :: Software Development

Tags

django test fixturesrandom model instance generationdjango factory testingtest data creation djangosmart object fixturesdjango model mocking
django-testingdeprecated

More Software Development packages