Skip to main content
django-shortuuidfield
----------------

Provides a ShortUUIDField for your Django models which uses the base-57 "Short UUID" package at https://github.com/stochastic-technologies/shortuuid/ .

Originally, a fork from David Cramer's excellent django-uuidfield, but not much is left of that besides a bit of structure.

Installation
============

Install it with pip (or easy_install)::

pip install django-shortuuidfield

Usage
=====

First you'll need to attach a ShortUUIDField to your class. This acts as a char(22) to maintain compatibility with SQL versions::

from shortuuidfield import ShortUUIDField

class MyModel(models.Model):
uuid = ShortUUIDField()

Enjoy!

Notes
=====

* ShortUUIDField is a subclass of django.db.models.CharField

* You can pass usual Django CharField parameters on init, although some of them are added/overwritten:
+ max_length=22 (since we are using base-57 format which is fixed at 22 characters)
+ blank=True, editable=False (set auto=False to remove these fields enforcement)

* Uses shortuuid.uuid() that generates uuid4 random values

Release files for django-shortuuidfield 0.1.3

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

Source distribution (sdist)

Source distribution for django-shortuuidfield 0.1.3
File Size Uploaded
django-shortuuidfield-0.1.3.tar.gz 3.4 kB Details

Release files / django-shortuuidfield-0.1.3.tar.gz

Download URL django-shortuuidfield-0.1.3.tar.gz
Size 3.4 kB
Tags Source
SHA-256 checksum
How to use checksums
a292c0fe5538abe947b131e2b914edd9ac44afcc6a40eaec71448e6231a3ef00
BLAKE2b-256 checksum
How to use checksums
7c01e192e8be3bdbcbfc63b9f4c33dbe874badd0bb49416fd98a20928fc3739b
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No

Release history Release notifications | RSS feed

This release

0.1.3 This release

1 release file

0.1.2

1 release file

0.1.1

1 release file

0.1.0

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