Skip to main content

Django Utils is a module with some convenient utilities not included with the standard Django install

Project description

Travis status:

https://travis-ci.org/WoLpH/django-utils.png?branch=master

Coverage:

https://coveralls.io/repos/WoLpH/django-utils/badge.png?branch=master

Django Utils is a collection of small Django helper functions, utilities and classes which make common patterns shorter and easier. It is by no means a complete collection but it has served me quite a bit in the past and I will keep extending it.

Examples are:

  • Enum based choicefields

  • Models with automatic __str__, __unicode__ and __repr__ functions based on names and/or slugs using simple mixins.

  • Models with automatic updated_at and created_at fields

  • Models with automatic slugs based on the name property.

  • Iterating through querysets in predefined chunks to prevent out of memory errors

The library depends on the Python Utils library.

Documentation is available at: http://django-utils-2.readthedocs.io/en/latest/

Install

To install:

  1. Run pip install django-utils2 or execute python setup.py install in the source directory

  2. Add django_utils to your INSTALLED_APPS

If you want to run the tests, run py.test (requirements in tests/requirements.txt)

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

django-utils2-2.7.0.tar.gz (14.1 kB view details)

Uploaded Source

Built Distribution

django_utils2-2.7.0-py2.py3-none-any.whl (16.5 kB view details)

Uploaded Python 2 Python 3

File details

Details for the file django-utils2-2.7.0.tar.gz.

File metadata

  • Download URL: django-utils2-2.7.0.tar.gz
  • Upload date:
  • Size: 14.1 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: Python-urllib/3.8

File hashes

Hashes for django-utils2-2.7.0.tar.gz
Algorithm Hash digest
SHA256 22ac61f587f6344eee36b14da7dcfb43e7ea38382e7d2941fa1a4dd2cd9fc2c5
MD5 05f7e8e56d78c330754625dd6c87e325
BLAKE2b-256 95bafeb577cdc125bdfb149d11f69c3a19fb0ee35a1aea81dcdd21f8fe9d3af7

See more details on using hashes here.

File details

Details for the file django_utils2-2.7.0-py2.py3-none-any.whl.

File metadata

File hashes

Hashes for django_utils2-2.7.0-py2.py3-none-any.whl
Algorithm Hash digest
SHA256 1af3a667026b8217a84b7e23be48764c32a46b19b94c952a7fd64d1d19e4f71b
MD5 74c9b02140704369dbbfb73ba11e1861
BLAKE2b-256 bbe940f5568d260f3803c0e3dd98d5b020a5224ef448c07b8d097434e366a9ce

See more details on using hashes here.

Supported by

AWS AWS Cloud computing and Security Sponsor Datadog Datadog Monitoring Fastly Fastly CDN Google Google Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page