Skip to content
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

DOC: Redirect moved pages #24705

Closed
datapythonista opened this issue Jan 10, 2019 · 3 comments · Fixed by #24715
Closed

DOC: Redirect moved pages #24705

datapythonista opened this issue Jan 10, 2019 · 3 comments · Fixed by #24715
Labels
Docs Needs Discussion Requires discussion from core team before further action

Comments

@datapythonista
Copy link
Member

Following up the discussion in #24451 (comment) and addressing the concerns of merging the PRs of #24499.

The problem is that we've moved many documentation pages (all the API pages, release.rst...) we'd like to move many more (almost every page). And we've got two options if we've been discussion so far are:

After thinking more on it, I think we can build a simpler redirect system than what we have, and keep redirects while reducing the complexity of the build.

What I'd do is create a file (e.g. doc/source/redirects.csv) containing the urls of the the old and new url (a line could look like io,user_guide/io or generated/pandas.DataFrame.to_parquet,api/reference/DataFrame/pandas.DataFrame.to_parquet)

Then, in doc/source/conf.py we open and iterate the file, and create a simple html in the old location with a link to the new. May be later we can use a nice template and a javascript that automatically redirects, but I'd keep it simple to start with.

If a page is splitted, we can have more than two columns in the csv (e.g. io,user_guide/io_plain,user_guide/io_binary), and show the two links in the redirect page.

I'd also move the current API redirect system to this, and we'd simplify conf.py.

@jorisvandenbossche @TomAugspurger does this sound good?

@datapythonista datapythonista added Docs Needs Discussion Requires discussion from core team before further action labels Jan 10, 2019
@TomAugspurger
Copy link
Contributor

I think that something like

<html>
    <head>
        <meta http-equiv="refresh" content="0;URL={{ destination }}.html />
    </head>
    <body>
    </body>
</html>

will automatically redirect users visiting the old page to the destination URL.

@datapythonista
Copy link
Member Author

Thanks @TomAugspurger , that works in Firefox for me, but added the message anyway, in case older browsers don't support it.

Opened #24715 with it.

@jorisvandenbossche
Copy link
Member

Thanks a lot for looking into this! Will try to take a look this weekend.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Docs Needs Discussion Requires discussion from core team before further action
Projects
None yet
Development

Successfully merging a pull request may close this issue.

3 participants