Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

...

For all other APIs it should allow the queries to go through.

Error Redirect Issues

The error redirect uses a full URL instead of a local one because otherwise the error page doesn't render properly. 

Given a relative local URL like /error/404.html the error page mostly fails to render properly. If the page that didn't exist is, for example, /1/2/3/4/index.html, then the URL will be kept as such, but the 404 page will be rendered as if it is in /1/2/3/4/. The js, css, and other assets will still have URLs expecting the page to be rendered at /error/404.html, so all of those assets 404 and thus a massive fail. This could potentially be fixed by making a custom page outside of the Sphinx theme, but at this point the URLs are generated and relative to the error page's actual location.

The drawback of using a full URL is that the HTTP header shows 302, not 404. This will confuse robots into thinking that the page does exist, and it is just in a new location. Instead we really should be giving a 404.

One approach could be to fix the theme issue as mentioned above or somehow exempt the error page from regular Sphinx theming. Then the local URL could be used.

Testing Redirects

Use the following curl example from command line to see the redirect's output without having to use the browser!

...