Skip to main content

GeneralManager

PyPI Python Build Coverage License: MIT

GeneralManager is a typed, declarative framework for building data-rich Django applications. Define domain objects once, then use the same model through the Django ORM, generated GraphQL, permission policies, validation, calculations, search, and workflows.

GeneralManager is pre-1.0. The main branch and latest PyPI release can differ; use the release history to distinguish published behavior from current development.

What GeneralManager provides

Domain models and interfaces

Start with the architecture overview and interface concepts.

APIs, permissions, and validation

Data and operations

Development and optional integrations

Compatibility

  • Python 3.12 or later
  • Django 5.2.17 or later

CI runs SQLite tests on Python 3.12, 3.13, and 3.14. Pull requests also run PostgreSQL 18 and MariaDB 11.8 LTS on Python 3.14; release runs cover those backends on Python 3.12–3.14. See installation and backend guidance.

Other database backends supported by Django may also work, but are not officially supported unless covered by GeneralManager’s test suite or maintained examples.

Five-minute setup

Start in an empty directory. On macOS or Linux:

mkdir general-manager-demo
cd general-manager-demo
python -m venv .venv
source .venv/bin/activate
python -m pip install --upgrade pip
python -m pip install GeneralManager
django-admin startproject gm_demo .
python manage.py startapp projects

Append the following to gm_demo/settings.py:

INSTALLED_APPS += [
    "general_manager",
    "projects.apps.ProjectsConfig",
]

AUTOCREATE_GRAPHQL = True
GRAPHQL_URL = "graphql/"
ALLOWED_HOSTS = ["127.0.0.1", "localhost", "testserver"]

Create projects/managers.py:

from typing import ClassVar

from django.db.models import CharField

from general_manager import GeneralManager
from general_manager.interface import DatabaseInterface
from general_manager.permission import AdditiveManagerPermission


class Project(GeneralManager):
    name: str

    class Interface(DatabaseInterface):
        name = CharField(max_length=100)

    class Permission(AdditiveManagerPermission):
        __read__: ClassVar[list[str]] = ["public"]
        __create__: ClassVar[list[str]] = ["isAuthenticated"]
        __update__: ClassVar[list[str]] = ["isAuthenticated"]
        __delete__: ClassVar[list[str]] = ["isAuthenticated"]

GeneralManager discovers managers.py modules in installed Django applications during startup, so no manual import in AppConfig.ready() is needed. Create the generated model's migration, initialize the database, and seed one demo record:

python manage.py makemigrations projects
python manage.py migrate
python manage.py shell -c 'from projects.managers import Project; Project.Factory.create(name="Apollo")'
python manage.py runserver

Project.Factory.create(...) is intended here for demo seeding. Application writes should run through an authenticated permission context.

In another terminal, retrieve the record through generated GraphQL. This GET request is copyable without a CSRF token:

curl --get 'http://127.0.0.1:8000/graphql/' \
  --data-urlencode 'query=query { projectList { items { name } } }'

Expected response:

{"data":{"projectList":{"items":[{"name":"Apollo"}]}}}

You now have a typed manager, generated Django model, migration, persisted record, permission policy, and generated GraphQL query. Continue with the annotated quickstart for Windows activation, framework behavior, and troubleshooting.

Documentation

Metadata

Release files for GeneralManager 0.94.0

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for GeneralManager 0.94.0
File Size Uploaded Provenance Actions
generalmanager-0.94.0.tar.gz 1.2 MB Without provenance Details for generalmanager-0.94.0.tar.gz

Built distribution (wheel)

Table of built distributions (wheels) for GeneralManager 0.94.0
File Interpreter ABI Platform Actions
generalmanager-0.94.0-py3-none-any.whl Python 3 none any Details for generalmanager-0.94.0-py3-none-any.whl

Total release size: 2.5 MB

Release files / generalmanager-0.94.0.tar.gz

Download URL generalmanager-0.94.0.tar.gz
Size 1.2 MB
Tags Source
SHA-256 checksum
How to use checksums
85a5ceca9df1586ad7763f9f98130380025e9448a58cbcb637870b0a4bf3c4a7
BLAKE2b-256 checksum
How to use checksums
3d8f81128828f26342bb4b10fbda2437678469cd008d0e2702ec5b1000eac4a0
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/6.0.1 CPython/3.12.16

Release files / generalmanager-0.94.0-py3-none-any.whl

Download URL generalmanager-0.94.0-py3-none-any.whl
Size 1.3 MB
Tags Python 3
SHA-256 checksum
How to use checksums
74237d58e6752d3cc764d60431e4b12659834718d0bd30edff5af194839a8b08
BLAKE2b-256 checksum
How to use checksums
6b5f61ed47a9f7eaa84cbe435028e195948ed038b8b45e45a8860a89675f1e1b
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/6.0.1 CPython/3.12.16

Security for GeneralManager 0.94.0

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

No provenance found

None of the files in this release were uploaded with provenance metadata.

A note on package security

PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.

To learn more about protecting yourself from malicious actors, visit our package security documentation.

Release history Release notifications | RSS feed

This release

0.94.0 This release

2 release files No provenance

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page