sphinx-notes/pages

Possibly dumb question...

rpgoldman opened this issue · 10 comments

When I build the docs for my project by invoking Sphinx manually, I get a _build/ directory with a _static/ subdirectory that contains needed components:

$ ls _build/_static/
basic.css                 documentation_options.js  jquery.js                 minus.png                 searchtools.js
css/                      file.png                  js/                       plus.png                  underscore-1.13.1.js
doctools.js               jquery-3.5.1.js           language_data.js          pygments.css              underscore.js

But when I generate my page using this GitHub action, that _static directory seems to be missing, and the resulting page does not display properly. See https://rpgoldman.github.io/pyDcop/

This is likely something obvious that I just don't understand: I took over a large project that had been abandoned, and I am afraid I don't understand its internals as well as I should.

I see in the docs for pages under "Tips" there is the following:

Copy extra files to site

Use Sphinx confval html_extra_path.

Unfortunately, the Sphinx documents for this conf value are so terse that this does not help; I can't tell if this is related to my problem.

Thank you for any suggestions.

Could this be related -- my .gitignore file contains the following:

# Sphinx documentation
docs/_build/

Could this keep the static materials from being committed to the gh-pages branch?

I do not believe this can be the problem, because when I look into the gh-pages files, the _static directory appears, see https://github.com/rpgoldman/pyDcop/tree/gh-pages/_static

It seems that the action works well, _static is correctly installed, but I don't know why we can not access it through github pages. Can you run the action again?

What's you gh-pages setting? For example:

image

It seems that the action works well, _static is correctly installed, but I don't know why we can not access it through github pages. Can you run the action again?

I just ran the action again, and I see the same poorly-formatted page.

I reloaded using Firefox's development tools and I see the following in the network window, which supports what you say:
image

Is there any way to see what is actually there on GitHub, so I can tell if

  1. those files failed to deploy, or
  2. the files were deployed, but permissions are not correct to serve them?

What's your gh-pages setting?

image

P.S. Thank you very much for helping!

You should enable extension sphinx.ext.githubpages in your conf.py first.

I think you forget to do this?

OK, I am sorry -- I made a mistake in configuration and forgot to push the change with the extension! Yes, that was the problem!

I pushed a commit to branch v2 for this, the sphinx.ext.githubpages extension is no longer needed, so we can use this action without change your sphinx conf.