Skip to main content

Custom exceptions for Django REST Framework

Project description

Custom exceptions for django rest framework


Works with :

  • Python 2.7, 3.4, 3.5, 3.6
  • Django >= 1.10
  • Django Rest Framework >= 3.5 Code Health


Install the package from pypi:

pip install djangorestframework-custom-exceptions

Add the application in your django settings:

INSTALLED_APPS = ('rest_framework_custom_exceptions',)

Configure your rest framework :

    'EXCEPTION_HANDLER': 'rest_framework_custom_exceptions.exceptions.simple_error_handler'


The simple error handler show exceptions like this :

    "error": "Not found"

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

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