docs: def error_404(request, exception):
      """Handle 404s outside of the valid API URL endpoints Note: Cannot raise NotFound()
      here, as this method is not covered by the GMN middleware handler that catches
      DataONE exceptions raised by normal views."""
      return django.http.HttpResponseNotFound(
          d1_common.types.exceptions.NotFound(
              0,
              'Invalid API endpoint',
              # Include the regexes the URL was tested against
              # traceInformation=str(exception),
              nodeId=django.conf.settings.NODE_IDENTIFIER,
          ).serialize_to_transport(xslt_url=django.urls.base.reverse('home_xslt')),
          d1_common.const.CONTENT_TYPE_XML,
      )