exceptions.py 474 B

12345678910111213141516171819
  1. from django.core.exceptions import PermissionDenied as DjPermissionDenied
  2. from django.http import Http404 as DjHttp404
  3. __all__ = ["PermissionDenied", "Http404", "OutdatedUrl"]
  4. class PermissionDenied(DjPermissionDenied):
  5. """The user did not have permission to do that"""
  6. pass
  7. class Http404(DjHttp404):
  8. """The requested page could not be found"""
  9. pass
  10. class OutdatedUrl(Exception):
  11. """The url that was used to reach view contained outdated slug"""