Importing exceptions: documentation should be more explicit and clearer
|Reported by:||EvilDMP||Owned by:||dominicrodger|
|Has patch:||yes||Needs documentation:||no|
|Needs tests:||no||Patch needs improvement:||no|
At https://docs.djangoproject.com/en/dev/ref/exceptions, for some of the listed exceptions information is provided on how to import it.
For example: "The UnreadablePostError is raised when a user cancels an upload. It is available from django.http."
For others though (e.g. https://docs.djangoproject.com/en/dev/ref/exceptions/#noreversematch) there isn't clear explicit information about where to get them from.
Also, when the information is provided, it's not always provided consistently.
My suggestion is that each section (Database Exceptions, Http Exceptions and so on) there should begin with a paragraph on its own: Core exceptions are provided in django.core.exceptions, Database exceptions are provided in django.db and so on.
FInally, Django-specific Exceptions seems a bit of a misnomer, since others not in that section are also Django-specific. Calling them Core exceptions would seem to make more sense.
Change History (6)
comment:1 Changed 3 years ago by bmispelon
- Needs documentation unset
- Needs tests unset
- Patch needs improvement unset
- Triage Stage changed from Unreviewed to Accepted
comment:2 Changed 3 years ago by dominicrodger
- Cc internet@… added
- Owner changed from nobody to dominicrodger
- Status changed from new to assigned
comment:5 Changed 3 years ago by Tim Graham <timograham@…>
- Resolution set to fixed
- Status changed from assigned to closed