-
-
Notifications
You must be signed in to change notification settings - Fork 3.6k
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
Duplicate static files with mkdocs #3497
Comments
Very specifically it looks like since the build is triggered twice, the extra CSS and JS are appended twice. See: https://github.com/rtfd/readthedocs.org/blob/4d10f2e/readthedocs/doc_builder/backends/mkdocs.py#L89-L97 |
Seems like the second build is triggered when synchronizing versions I'm going to investigate more about this in the next days |
On readthedocs.org works fine, is this something that just affect to local instances? or maybe a recent regression (I'm not sure what commit is on production right now)? |
Also experienced with this repo https://github.com/orbingol/NURBS-Python (local instance only) |
I can't replicate this anymore, I think this was something to do with #3946. @davidfischer can you confirm if this issue is solved? |
I'm not seeing it! It is fixed. |
Details
On the very first build of a brand new mkdocs project, the docs build runs twice which creates duplicate CSS and JS files in the
<head>
of the output. When a project is built a second time, this error does not manifest itself.To reproduce locally, do a manual project import of mkdocs itself and trigger a build.
Expected Result
The HTML build should only run once and there should be no duplicate CSS and JS files referenced in the output.
Actual Result
The output HTML references the same CSS and JS files multiple times.
This first screenshot illustrates that additional CSS and JavaScript files are added twice.
This second screenshot illustrates that the
extra_css
andextra_javascript
have duplicates in the mkdocs.yml file.The text was updated successfully, but these errors were encountered: