-
-
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
Setting up latest mkdocs in RTD configuration does not result with the actual latest mkdocs version. #7539
Comments
Pinging @pchote and @Mailaender for interest. |
You can install any version of mkdocs you want, see https://docs.readthedocs.io/en/stable/guides/specifying-dependencies.html |
Yes, I understand this part. Manually pinning the latest version shouldn't be the solution to circumvent an outdated default value though. The feature flag added in #5505 seems to cause the problem here - it was added to hold back then-existing documentation instances of mkdocs to 0.17.0. However the way it was set up, it kept the latest version to 1.0 (1.1 was in-dev during that time). 1.1 was released, and received bugfix releases since as well which regressed RTD at mkdocs documentations which does not pin the required versions to latest on their own. |
We need to pin our dependencies in some way to try to make them deterministic. At some point those default will be outdated and we need to come up with a plan to update the default values. We have the same problem with Sphinx right now and it's not easy to update the versions and keep every user happy with the new default. |
@GraionDilach we recommend pinning to a specific version so your builds don't break if we update the default version, also if gives you a way to have the exact build locally. |
An example of how a |
your requirements.txt file should be like
|
Thanks. I tried it. OpenHV/docs@0686167 but it regresses in terms of the table of contents and also doesn't fix the syntax highlighting as expected. |
Please report those problems to the mkdocs repo |
Setting
or
also didn't help. Only deleting |
@Mailaender please link to your project and also see if you can replicate locally with the same version |
This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions. |
I also noticed a difference in my table of contents compared to the version of mkdocs I tested with locally. I noticed the theme was part of
But the theme still looks different. Strangely, in the build log, I can see this occurring:
And then this next:
Which results in two installs of I'm trying to understand why my local install of Update: somehow the theme now looks the same. I didn't change anything 🤷 |
It may have been a cached page. Also, we install a default version of mkdocs, but you can install any version you require, that's why is installed twice, the second installation is the one being used. |
So even with latest version pinned, apparently the problem with mkdocs would actually come from RTD: mkdocs/mkdocs#2145 (comment)
|
We set that value here if isn't present.
I think maybe old versions of mkdocs didn't a default value? Still, if so the docs wouldn't build locally, so I think we shouldn't edit that setting. Another possibility is that this was added for users that didn't have a mkdocs.yaml file (think this may be the case actually) #2483. |
This value has been the default since the start of the project https://github.com/mkdocs/mkdocs/blob/0.13.0/mkdocs/config/defaults.py#L44 We should respect that default value, (we should actually don't edit it at all #2483). So, instead of trying to guess the docs dir always, only try to guess it if the user doesn't have mkdocs.yaml file. This should avoid any backwards compatibility and avoid weird bugs to new users. Closes #7539
This value has been the default since the start of the project https://github.com/mkdocs/mkdocs/blob/0.13.0/mkdocs/config/defaults.py#L44 We should respect that default value, (we should actually don't edit it at all #2483). So, instead of trying to guess the docs dir always, only try to guess it if the user doesn't have mkdocs.yaml file. This should avoid any backwards compatibility and avoid weird bugs to new users. Closes #7539
This fix should be live by next tuesday. |
@Zylann the fix is live now, if you want to give it a try :) |
I removed my workaround and it seems to work this time. Thank you! |
Details
OpenRA/OpenRA#18681 is a WIP update in the @OpenRA project documentation. During the PR review, it was noticed that the generated document featured mkdocs/mkdocs#2027. This bug is fixed in mkdocs version 1.1.1 - mkdocs/mkdocs@63b3eb5 - already but RTD does not deploy the bugfix.
I don't know Python but I suspect
https://github.com/readthedocs/readthedocs.org/blob/master/readthedocs/doc_builder/python_environments.py#L373 caps the version to 1.1 which became outdated by now (blame claims it's a two year old line) and prevents RTD to deploy versions above 1.1.
Expected Result
Setting mkdocs to use the latest release deploys on mkdocs's latest release.
Actual Result
Setting mkdocs to use the latest release deploys on mkdocs version 1.1 instead of 1.1.2.
The text was updated successfully, but these errors were encountered: