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

Possible path error? #831

Closed
pedro-w opened this issue Oct 11, 2019 · 3 comments · Fixed by #838
Closed

Possible path error? #831

pedro-w opened this issue Oct 11, 2019 · 3 comments · Fixed by #838
Labels
Priority: low Low priority

Comments

@pedro-w
Copy link

pedro-w commented Oct 11, 2019

Not sure if this is intentional or not but in this line:

html_theme_path = ["../.."]

html_theme_path points to a directory outside the repo. So on my system when I build I get warnings like

WARNING: file 'imlv.zip' on theme path is not a valid zipfile or contains no theme

where imlv.zip just happens to be a zip file with the same parent directory as sphinx_rtd_theme.

@agjohnson
Copy link
Collaborator

You may be right, though I also think that option doesn't have any effect locally or on the RTD hosted version. Locally, we import the template after appending the local path to the theme (../) -- here:

sys.path.insert(0, os.path.abspath('..'))

On RTD, the theme is installed from PyPI, and so the html_theme_path option isn't used there either.

Perhaps try removing the option and see if that breaks anything. My guess is it should work both locally and on RTD.

@agjohnson agjohnson added the Priority: low Low priority label Oct 15, 2019
@agjohnson
Copy link
Collaborator

I ended up testing this in #838 and the line is removed there. Change looks good so far

@pedro-w
Copy link
Author

pedro-w commented Nov 7, 2019

Sorry I didn't get back to you on this. I did do some testing and as far as I could see it didn't cause any problems - but on the other hand I couldn't make it do anything terrible by having a wayward zip in the parent folder. Removing the line does stop that warning appearing though, so I think it's worth doing.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Priority: low Low priority
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants