Skip to main content

BitmaskField implementation for Django ORM

Project description

BitmaskField implementation for Django ORM


  • Python 2.7 or Python 3.4+
  • Django 1.8+


from django.db import models
from django_bitmask_field import BitmaskField

class MyModel(models.Model):

    bitmask = BitmaskField(
        choices=[(1, 'bit0'), (2, 'bit1'), (4, 'bit2')],  # available choices
        default=1 | 4,  # bit0 and bit2 are enabled by default


pip install django-bitmask-field

Download files

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

Source Distribution

django-bitmask-field-0.1.3.tar.gz (4.1 kB view hashes)

Uploaded source

Built Distribution

Supported by

AWS AWS Cloud computing Datadog Datadog Monitoring Facebook / Instagram Facebook / Instagram PSF Sponsor Fastly Fastly CDN Google Google Object Storage and Download Analytics Huawei Huawei PSF Sponsor Microsoft Microsoft PSF Sponsor NVIDIA NVIDIA PSF Sponsor Pingdom Pingdom Monitoring Salesforce Salesforce PSF Sponsor Sentry Sentry Error logging StatusPage StatusPage Status page