Avoid ValueError in admin when passing a string as PK for an inherited model with an integer PK field
|Reported by:||anonymous||Owned by:||ikks|
|Severity:||Normal||Keywords:||admin inheritance integer PK|
|Has patch:||yes||Needs documentation:||no|
|Needs tests:||no||Patch needs improvement:||no|
In the admin if the PK for an inherited model is passed an string an error 500 is raised, the resulting status_code should be 404, the Exception throws a ValueError.
For example if in the tests the SuperVillain class is tried to be accessed with a wrong PK, like abc, the status_code is 500 and it should be 404.
Change History (3)
comment:1 Changed 2 years ago by ikks
- Easy pickings set
- Has patch set
- Needs documentation unset
- Needs tests unset
- Owner changed from nobody to ikks
- Patch needs improvement unset
- Status changed from new to assigned