Uploaded image for project: 'Calcite'
  1. Calcite
  2. CALCITE-2036

/docs/powered_by.html has a next of /docs/api.html which does not exist

    Details

    • Type: Bug
    • Status: Closed
    • Priority: Minor
    • Resolution: Resolved
    • Affects Version/s: 1.14.0
    • Fix Version/s: None
    • Component/s: site
    • Labels:
      None

      Description

      The bottom of this page: https://calcite.apache.org/docs/powered_by.html
      has two buttons: previous and next.
      The "next" points to https://calcite.apache.org/docs/api.html
      which is absent.

      The site/_data/docs.yml has "api" item after "powered_by" item.
      And site/_includes/section_nav.html makes the "next" link to have ".html" appended.
      Thus "api.html" string is created.

        Activity

        Hide
        alexeyroytman Alexey Roytman added a comment -

        Checked Avatica, too, and it's OK now. Closing.

        Show
        alexeyroytman Alexey Roytman added a comment - Checked Avatica, too, and it's OK now. Closing.
        Hide
        michaelmior Michael Mior added a comment -

        Sorry, missed that comment. This is fixed for Avatica now as well.

        Show
        michaelmior Michael Mior added a comment - Sorry, missed that comment. This is fixed for Avatica now as well.
        Hide
        alexeyroytman Alexey Roytman added a comment -

        What shall we say about the same issue on the Avatica site (see my 1st comment)?

        Show
        alexeyroytman Alexey Roytman added a comment - What shall we say about the same issue on the Avatica site (see my 1st comment)?
        Hide
        alexeyroytman Alexey Roytman added a comment -

        Checked the site – works. Closing.

        Show
        alexeyroytman Alexey Roytman added a comment - Checked the site – works. Closing.
        Hide
        michaelmior Michael Mior added a comment -

        Done. I was going to avoid it because this resulted in partial changes to files. I ended up just using git-svn to commit only the changed parts so this should be live soon.

        Show
        michaelmior Michael Mior added a comment - Done. I was going to avoid it because this resulted in partial changes to files. I ended up just using git-svn to commit only the changed parts so this should be live soon.
        Hide
        julianhyde Julian Hyde added a comment -

        I sometimes deploy the site selectively. For example I recently deployed community.html to add some talks but did not deploy reference.html with features that will only arrive in 1.15. I think that would be appropriate here.

        Show
        julianhyde Julian Hyde added a comment - I sometimes deploy the site selectively. For example I recently deployed community.html to add some talks but did not deploy reference.html with features that will only arrive in 1.15. I think that would be appropriate here.
        Hide
        michaelmior Michael Mior added a comment -

        Fixed in 830801b6e. Not deploying immediately since it looks like there are other site changes that I'm not sure should be live right now.

        Show
        michaelmior Michael Mior added a comment - Fixed in 830801b6e . Not deploying immediately since it looks like there are other site changes that I'm not sure should be live right now.
        Hide
        julianhyde Julian Hyde added a comment -

        I saw your fix 830801b6. Let me know if you'd like me to re-deploy the site.

        Show
        julianhyde Julian Hyde added a comment - I saw your fix 830801b6 . Let me know if you'd like me to re-deploy the site.
        Hide
        julianhyde Julian Hyde added a comment -

        Sounds good. Since this is the site, not the product, hacks are fine!

        Show
        julianhyde Julian Hyde added a comment - Sounds good. Since this is the site, not the product, hacks are fine!
        Hide
        michaelmior Michael Mior added a comment -

        Good point. It's a bit of a hack, but I could just add a replace that changes /docs/api.html to /apidocs/ since this is the only case that happens (we don't have next/previous links on the API pages). Tested this and it works. Sound good?

        Show
        michaelmior Michael Mior added a comment - Good point. It's a bit of a hack, but I could just add a replace that changes /docs/api.html to /apidocs/ since this is the only case that happens (we don't have next/previous links on the API pages). Tested this and it works. Sound good?
        Hide
        julianhyde Julian Hyde added a comment -

        I'm not an expert in jekyll, but the simplest thing might be to change the code that generates the "next" button.

        Show
        julianhyde Julian Hyde added a comment - I'm not an expert in jekyll, but the simplest thing might be to change the code that generates the "next" button.
        Hide
        julianhyde Julian Hyde added a comment -

        If it's just some one-time changes to pages, that's OK. Or would it be more than that?

        I'm also worried that the redirect may not work well if there are parameters at the end of the URL. For example, what would the URL https://calcite.apache.org/apidocs/org/apache/calcite/rel/RelNode.html#getInput-int- (for the method RelNode.getInput(int)) be in the new scheme?

        Show
        julianhyde Julian Hyde added a comment - If it's just some one-time changes to pages, that's OK. Or would it be more than that? I'm also worried that the redirect may not work well if there are parameters at the end of the URL. For example, what would the URL https://calcite.apache.org/apidocs/org/apache/calcite/rel/RelNode.html#getInput-int- (for the method RelNode.getInput(int) ) be in the new scheme?
        Hide
        alexeyroytman Alexey Roytman added a comment -

        Ok. We may say that in the list, after powered_by goes ../apidocs/
        And then, in the post-processing (the one that adds ".html"), we don't add ".html" to a section that either starts with "../" or ends with "/".

        Show
        alexeyroytman Alexey Roytman added a comment - Ok. We may say that in the list, after powered_by goes ../apidocs/ And then, in the post-processing (the one that adds ".html"), we don't add ".html" to a section that either starts with "../" or ends with "/".
        Hide
        michaelmior Michael Mior added a comment -

        I'd like to avoid creating extra files or having an extra chain of redirects if possible. But the easiest solution is as I proposed above.

        Show
        michaelmior Michael Mior added a comment - I'd like to avoid creating extra files or having an extra chain of redirects if possible. But the easiest solution is as I proposed above.
        Hide
        alexeyroytman Alexey Roytman added a comment -

        We may actually create /docs/api.html (for Calcite and for Avatica) that will have an immediate refresh/redirect to "/docs/api" (or "/docs/api/index.html") or even straight to "/apidocs".

        Show
        alexeyroytman Alexey Roytman added a comment - We may actually create /docs/api.html (for Calcite and for Avatica) that will have an immediate refresh/redirect to "/docs/api" (or "/docs/api/index.html") or even straight to "/apidocs".
        Hide
        michaelmior Michael Mior added a comment -

        Julian Hyde The problem seems to be that since permalink is not set for api.md, it is placed in /docs/api/index.html instead of /docs/api.html. This is resolved by setting the permalink, but has the side effect of changing a bunch of existing links from pointing to /apidocs to pointing to /docs/api.html. Of course, this redirects to /apidocs anyway, but it would be nice not put in a bunch of unnecessary redirects. Thoughts?

        Show
        michaelmior Michael Mior added a comment - Julian Hyde The problem seems to be that since permalink is not set for api.md , it is placed in /docs/api/index.html instead of /docs/api.html . This is resolved by setting the permalink, but has the side effect of changing a bunch of existing links from pointing to /apidocs to pointing to /docs/api.html . Of course, this redirects to /apidocs anyway, but it would be nice not put in a bunch of unnecessary redirects. Thoughts?
        Show
        alexeyroytman Alexey Roytman added a comment - Same for avatica: https://calcite.apache.org/avatica/docs/history.html and its "next" is: https://calcite.apache.org/avatica/docs/api.html

          People

          • Assignee:
            michaelmior Michael Mior
            Reporter:
            alexeyroytman Alexey Roytman
          • Votes:
            0 Vote for this issue
            Watchers:
            3 Start watching this issue

            Dates

            • Created:
              Updated:
              Resolved:

              Development