-
Notifications
You must be signed in to change notification settings - Fork 21
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
Better 404 pages/redirection for static index meta-databases #76
Comments
The other option would be to redirect all "raw" base URLs to the appropriate links endpoint. |
I see you've already implemented this in #77, but I'm not sure this is the "correct" way to handle this. However, it is convenient. Personally, I'd prefer a web page response, as I may be a confused client going to the base URL and suddenly be redirected to a functional entry endpoint - it seems off, but it's very practical. |
We can change my redirects to instead serve a custom 404 page (for just the providers base URLs), but what info should be on it? We can't use a templating engine or anything, so I don't think we can provide a link to the links endpoint, or serve any provider-specific data as we do in the OPT landing page (unless there are some HTML-only hacks for relative redirects/getting the current requested URL). Other option of generating a 404 page per provider and committing in this repo seems like too large a burden to me. |
I would just add some hard-coded "common shortcomings/mistakes" list with a mention of "did you remember to add the major version and endpoint to the path?" or something? |
Have updated my PR with something along these lines. |
Closed by #77 |
It would be good to have a better default 404 template, such that when someone visits e.g. http://providers.optimade.org/index-metadbs/tcod, they get a link to the appropriate links endpoint. This has come up a few times in tutorials and other issues (#75, Materials-Consortia/providers-dashboard#60 and #74 (comment))
The text was updated successfully, but these errors were encountered: