Skip to main content

entirius-django-utils

Shared Django building blocks for the modules of Entirius, the open-source modular ecommerce platform. Abstract base models, DRF API helpers, admin base classes, text tools and an AI toolbox client live here, so every module builds on the same foundations.

PyPI Python License: MPL-2.0

What it does

  • Abstract base models and manager helpers shared by every Entirius module.
  • DRF helpers: request parsing, filtering, pagination and the structured v2 error handling.
  • Admin base classes, text, slug and translation helpers.
  • A base for worker management commands with locking.
  • A typed client for the AI toolbox (completions, model catalogue, error mapping to DRF responses).

Installation

uv add entirius-django-utils
pip install entirius-django-utils

Optional extra: entirius-django-utils[unfold] (django-unfold admin theme).

INSTALLED_APPS = [
    ...
    "django_regional",
    "django_utils",
]

The toolbox client needs AI_TOOLBOX_BASE_URL, AI_TOOLBOX_API_KEY and AI_TOOLBOX_CHANNEL; the settings reference is https://github.com/entirius/entirius-django-utils/blob/develop/docs/toolbox-client.md.

Quick start

from django_utils.toolbox import CompletionRequest, Message, ToolboxClient

# settings: AI_TOOLBOX_BASE_URL = "https://toolbox.example.com"
with ToolboxClient() as client:
    response = client.complete(
        CompletionRequest(
            model="fake-chat",
            messages=[Message(role="user", content="Say hi as JSON")],
            json_schema={"type": "object"},
        )
    )

Requirements

  • Python 3.11 or newer, Django 4.2 or newer.
  • Entirius packages pulled in: entirius-django-regional, entirius-py-idx-normalizator, entirius-py-process-logger.

Documentation

Part of Entirius

Every module of the Entirius backend service (Volkanos) depends on this package.

Development

make install     # sync dependencies (uv)
make check       # lint + format check (ruff)
make test        # test suite (pytest + pytest-django)

Development and agent instructions: https://github.com/entirius/entirius-django-utils/blob/develop/AGENTS.md

License

Mozilla Public License 2.0 (MPL-2.0) — see https://github.com/entirius/entirius-django-utils/blob/develop/LICENSE.

Metadata

Release files for entirius-django-utils 2.4.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 entirius-django-utils 2.4.0
File Size Uploaded Provenance Actions
entirius_django_utils-2.4.0.tar.gz 92.0 kB Without provenance Details for entirius_django_utils-2.4.0.tar.gz

Built distribution (wheel)

Table of built distributions (wheels) for entirius-django-utils 2.4.0
File Interpreter ABI Platform Actions
entirius_django_utils-2.4.0-py3-none-any.whl Python 3 none any Details for entirius_django_utils-2.4.0-py3-none-any.whl

Total release size: 134.2 kB

Release files / entirius_django_utils-2.4.0.tar.gz

Download URL entirius_django_utils-2.4.0.tar.gz
Size 92.0 kB
Tags Source
SHA-256 checksum
How to use checksums
d005b9a11019c50723795800cb059f113d781d9fa4c82ff4beb3ac01cc635802
BLAKE2b-256 checksum
How to use checksums
2debacd7d69fab3c0a138f3fdb4459aa62f905c51263e8695dba561c1b540dd1
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via uv/0.13.6 {"installer":{"name":"uv","version":"0.13.6","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"Ubuntu","version":"24.04","id":"noble","libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":true}

Release files / entirius_django_utils-2.4.0-py3-none-any.whl

Download URL entirius_django_utils-2.4.0-py3-none-any.whl
Size 42.2 kB
Tags Python 3
SHA-256 checksum
How to use checksums
4fcb6121e8d3b4652c8a966e40f886bb85615ce86002b0a3a1c5d2e5350a80bf
BLAKE2b-256 checksum
How to use checksums
6a4384cb2ebea2bfb6f99f0507663724cb81e4b0fc640a67c1b52b8fa2f6a1f4
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via uv/0.13.6 {"installer":{"name":"uv","version":"0.13.6","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"Ubuntu","version":"24.04","id":"noble","libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":true}

Security for entirius-django-utils 2.4.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.

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