django · django/ObjectDoesNotExist
ObjectDoesNotExist
ObjectDoesNotExist
Base class for all model-specific DoesNotExist exceptions. Catching ObjectDoesNotExist handles missing-record errors for any model type in a single except clause, useful in generic views and shared utility functions.