crate / crate-docs-theme

A Sphinx theme for the CrateDB documentation.

Home Page:https://crate-docs-theme.readthedocs.io/

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

SQL-99 RTD URL errors

msbt opened this issue · comments

Super low priority, because this affects only assets from readthedocs, but I prefer to not have errors in the browser console ;) Since we changed the URL to be external, we also need to update html_baseurl, canonical_url_path and url_path of the project

https://github.com/crate/crate-docs-theme/blob/main/src/crate/theme/rtd/conf/sql_99.py#L31-L41 for reference. Do you reckon it's enough if we set the following:

from
url_path = "docs/sql-99"to
url_path = ""

from
html_baseurl = "https://cratedb.com/%s/" % url_path to
html_baseurl = "https://sql-99.readthedocs.io" % url_path or even omit the % url_path altogether for this and the next?

from
"canonical_url_path": "%s/en/latest/" % url_path, to
"canonical_url_path": "/en/latest/" % url_path,

If you could confirm that this is how it's supposed to be, I'm happy to create a PR.

Hi Matthias. Your proposal looks good, but I can't tell if it will work. The intertwingulation on this level is of such a shape that I am exclusively approaching corresponding changes on a trial-and-error basis.

Feel free to create a PR to just probe if it works. When it doesn't, we'll improve or revert.

Hah good point, #464 for reference