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

Fix mkdocs relpath #5749

Merged
merged 2 commits into from
May 31, 2019
Merged

Conversation

stsewd
Copy link
Member

@stsewd stsewd commented May 31, 2019

After #5377
The code calling the config module is in charge of getting the full
path.

After readthedocs#5377
The code calling the config module is in charge of getting the full
path.
@davidfischer
Copy link
Contributor

I encountered this error here. I was able to reproduce it on the same repo locally. This PR did fix the issue.

Call mkdocs with relative path
we are already setting the cwd to the full checkout path
@@ -248,7 +248,7 @@ def build(self):
'--site-dir',
self.build_dir,
'--config-file',
self.yaml_file,
os.path.relpath(self.yaml_file, self.root_path),
Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

One test was expecting this call to be relative to the checkout path, but with the new change this was a full path.
Relative path is shorter to show in the output and we are already setting the cwd to the checkout path, so we are fine.

@stsewd
Copy link
Member Author

stsewd commented May 31, 2019

I also checked all the usages of self.yaml_file, they are good

@stsewd stsewd requested a review from a team May 31, 2019 14:11
@ericholscher ericholscher merged commit 9ca5858 into readthedocs:master May 31, 2019
@ericholscher
Copy link
Member

@stsewd do you think this should be hotfixed today?

@stsewd
Copy link
Member Author

stsewd commented May 31, 2019

@ericholscher yeah, it affects people using mkdocs with a rtd configuration file. Which I think are most of our users now

@stsewd stsewd deleted the fix-mkdocs-relpath branch May 31, 2019 14:36
ericholscher added a commit that referenced this pull request May 31, 2019
ericholscher added a commit that referenced this pull request May 31, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants