Opened 6 years ago

Closed 6 years ago

#11784 closed (wontfix)

exceptions should sublcass StandardError, not Exception

Reported by: anonymous Owned by: nobody
Component: Core (Other) Version: 1.1
Severity: Keywords: exception
Cc: Triage Stage: Unreviewed
Has patch: yes Needs documentation: no
Needs tests: no Patch needs improvement: no
Easy pickings: UI/UX:


a quick look at the standard python library's exception hierarchy ( ) will show that in all but a few special cases, exceptions should subclass StandardError. all of django's exceptions subclass the parent class of StandardError, Exception. In addition to being good practice to keep a clean class hierarchy, coders accustomed to catching StandardError may have unexpected results when using django.

Attachments (1)

django_exception.patch (1.5 KB) - added by anonymous 6 years ago.
patch to subclass StandardError

Download all attachments as: .zip

Change History (2)

Changed 6 years ago by anonymous

patch to subclass StandardError

comment:1 Changed 6 years ago by dc

  • Needs documentation unset
  • Needs tests unset
  • Patch needs improvement unset
  • Resolution set to wontfix
  • Status changed from new to closed

exception Exception

All built-in, non-system-exiting exceptions are derived from this class. All user-defined exceptions should also be derived from this class.

Note: See TracTickets for help on using tickets.
Back to Top