-
Notifications
You must be signed in to change notification settings - Fork 32
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Mention that simple local webservers often don't handle 404s by default #95
Comments
Hi! Thanks for sharing this. It's interesting that you can add the handler to make it work locally without too much code. I don't think the documentation needs to go too deep on this, but maybe worth to mention it in the FAQ. We do have a warning note saying that Maybe we can link to a FAQ from that note, explain a little more there and link to the Stack Overflow solution? |
Doh, I did a bad job of putting on my "new user" hat and somehow clicked on every page but installation. If I had to guess, it was because the installation is pretty much documented in the README as well, so I decided to skip that page thinking I had already read that content. (For backstory, I happened to see someone else using the extension get confused by the lack of a 404, so I was attempting to be helpful.) Adding it to the FAQ sounds like a good idea. I don't mind making a PR if you want. Maybe: Why is my local webserver not showing a 404.html?
-------------------------------------------------
Simple webservers, such as ``http.server``, don't have a default handler for 404 codes, so it doesn't know to point to the generated ``404.html``.
To see an example of adding a custom request handler for 404 codes, see: https://stackoverflow.com/questions/22467908/python-simplehttpserver-404-page And append to the installation warning: If you can't see the 404.html file using a local simple webserver, it is most likely because they often don't support requests for 404 codes. Refer to the :doc:`faq` for more information. |
Add warning about local web server for #95
I don't know if it is worth mentioning in the docs somewhere, but
http.server
(and other simple webservers I'm sure) don't have a default handler for 404 codes, so people might run into issues when attempting to test out the extension locally.I also don't know if the docs would need to go this far, but here is an example of adding a custom request handler for 404 codes: https://stackoverflow.com/questions/22467908/python-simplehttpserver-404-page
The text was updated successfully, but these errors were encountered: