Skip to content

DOC/CI: Fix building docs with --no-api #38858

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

Merged
merged 2 commits into from
Jan 13, 2021

Conversation

rhshadrach
Copy link
Member

  • closes #xxxx
  • tests added / passed
  • passes black pandas
  • passes git diff upstream/master -u -- "*.py" | flake8 --diff
  • whatsnew entry

Fixes running docs via

 python make.py --no-api

A few notes:

  • The removed check if os.path.exists(path):; will incorrectly raise if docs are being rebuilt.
  • The value dirname returned by os.walk is an absolute path, but the check was treating it as relative.
  • If docs are built with api and then rebuilt with --no-api, we want to exclude everything in the reference directory; in particular reference/api.

@rhshadrach rhshadrach added CI Continuous Integration Docs labels Dec 31, 2020
@rhshadrach
Copy link
Member Author

@github-actions pre-commit

@jreback
Copy link
Contributor

jreback commented Jan 13, 2021

lgtm.

Copy link
Member

@jorisvandenbossche jorisvandenbossche left a comment

Choose a reason for hiding this comment

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

Thanks, looks good!

if os.path.exists(path):
raise RuntimeError(
f"Redirection would overwrite an existing file: {path}"
)
Copy link
Member

Choose a reason for hiding this comment

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

Thanks, I regularly ignored this error .. ;)

@jorisvandenbossche jorisvandenbossche merged commit cca4901 into pandas-dev:master Jan 13, 2021
@rhshadrach rhshadrach deleted the fix_no_api branch January 13, 2021 15:03
luckyvs1 pushed a commit to luckyvs1/pandas that referenced this pull request Jan 20, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
CI Continuous Integration Docs
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants