An HTTP 404 Not Found response tells the browser that the requested resource could not be found. In Django, a missing database object can become a 404 page instead of a crash or an empty result. section 4.6.1 section 8.4
A common detail-view flow captures an integer from the URL, passes it to get_object_or_404(), and renders the object when found. If the lookup finds nothing—or does not identify one object—the shortcut raises Http404; Django catches it and returns the 404 response. section 4.6.1
A missing musician
The route /bands/musician/100/ passes 100 as musician_id. If no Musician has that ID, the detail page is replaced by a 404 page. A real URL is public input, so the view must handle typed or otherwise invalid arguments rather than trusting links to be correct. section 4.6.1


