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

Add docs build job #868

Merged
merged 35 commits into from
Feb 15, 2023
Merged

Conversation

AyodeAwe
Copy link
Contributor

The PR adds a docs_build process to the PR and Build workflows for this repository. The generated docs are synced to s3 for only the build workflows.

@github-actions github-actions bot added the ci label Jan 23, 2023
@AyodeAwe AyodeAwe added the non-breaking Non-breaking change label Jan 23, 2023
@AyodeAwe AyodeAwe added the improvement Improvement / enhancement to an existing function label Jan 24, 2023
@codecov-commenter
Copy link

codecov-commenter commented Jan 24, 2023

Codecov Report

Base: 92.60% // Head: 92.60% // No change to project coverage 👍

Coverage data is based on head (1a203c1) compared to base (870b164).
Patch has no changes to coverable lines.

Additional details and impacted files
@@              Coverage Diff              @@
##           branch-23.02     #868   +/-   ##
=============================================
  Coverage         92.60%   92.60%           
=============================================
  Files                24       24           
  Lines              1014     1014           
=============================================
  Hits                939      939           
  Misses               75       75           

Help us with your feedback. Take ten seconds to tell us how you rate us. Have a feature suggestion? Share it here.

☔ View full report at Codecov.
📢 Do you have feedback about the report comment? Let us know in this issue.

@github-actions github-actions bot added the conda Related to conda and conda configuration label Jan 24, 2023
@AyodeAwe AyodeAwe marked this pull request as ready for review January 25, 2023 16:00
@AyodeAwe AyodeAwe requested a review from a team as a code owner January 25, 2023 16:00
Copy link
Member

@ajschmidt8 ajschmidt8 left a comment

Choose a reason for hiding this comment

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

Looks good. Added a few comments

ci/build_docs.sh Outdated Show resolved Hide resolved
ci/build_docs.sh Outdated Show resolved Hide resolved
ci/build_docs.sh Outdated Show resolved Hide resolved
ci/build_docs.sh Outdated Show resolved Hide resolved
dependencies.yaml Outdated Show resolved Hide resolved
dependencies.yaml Outdated Show resolved Hide resolved
@AyodeAwe
Copy link
Contributor Author

Warning, treated as error:
/opt/conda/envs/docs/lib/python3.9/site-packages/cuspatial/core/geoseries.py:docstring of cuspatial.core.geoseries.GeoSeries.contains_properly:39:Unexpected indentation.

ci/build_docs.sh Outdated Show resolved Hide resolved
ci/build_docs.sh Outdated Show resolved Hide resolved
dependencies.yaml Show resolved Hide resolved
@AyodeAwe AyodeAwe changed the base branch from branch-23.02 to branch-23.04 February 2, 2023 15:38
dependencies.yaml Outdated Show resolved Hide resolved
dependencies.yaml Outdated Show resolved Hide resolved
@AyodeAwe AyodeAwe requested a review from vyasr February 10, 2023 14:20
@review-notebook-app
Copy link

Check out this pull request on  ReviewNB

See visual diffs & provide feedback on Jupyter Notebooks.


Powered by ReviewNB

@github-actions github-actions bot added the Python Related to Python code label Feb 10, 2023
Copy link
Contributor

@thomcom thomcom left a comment

Choose a reason for hiding this comment

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

Are these inline pydocs changes purposeful? I ask because it seems like there would be a lot more changes across the codebase to match the new formatting requirement, if there is one.

.github/workflows/build.yaml Outdated Show resolved Hide resolved
.github/workflows/pr.yaml Outdated Show resolved Hide resolved
@ajschmidt8
Copy link
Member

Are these inline pydocs changes purposeful? I ask because it seems like there would be a lot more changes across the codebase to match the new formatting requirement, if there is one.

@thomcom, we've enabled the -W flag for the Sphinx builds, which treats warnings as errors (e.g. these).

It seems like there are only 11 warnings and they all look whitespace related, so it shouldn't be too hard for us to address them in this PR.

If it gets out of hand, we can address them in a follow-up PR.

According to the [`autodoc` documentation](https://www.sphinx-doc.org/en/master/usage/extensions/autodoc.html), `autodoc` will automatically import the modules to be documented.

The CI docs building process will install the packages that were built in previous stages of the workflow and presumably `autodoc` will import those correctly, which means these lines are not needed.
@ajschmidt8
Copy link
Member

I've just pushed a few additional changes and some reversions.

I think this is almost the minimum set of changes needed to build the docs without any warnings.

I'm expecting the latest commit as of this writing (4f60b18) to throw a duplicate label error from the autosectionlabel plugin.

Once that happens, I will push the change below to suppress it since it's a relatively benign warning.

suppress_warnings = [
    "autosectionlabel.*"
]

It stems from the fact that the https://docs.rapids.ai/api/cuspatial/nightly/user_guide/cuspatial_api_examples.html page has two section headers called cuspatial.polygon_bounding_boxes.

As a result of this, the first occurrence gets a correct anchor attached, but the second occurrence gets an anchor of #id1. See here:

The consequence of this is that you can't confidently link to either section using the :ref: syntax outlined in the autosectionlabel docs since there is a duplicately named section.

However, I didn't see any instances of :ref: being used anywhere.

@thomcom, I'll defer to you to determine if you want to leave the suppress_warnings entry or properly address the warning in a follow-up PR.

@ajschmidt8
Copy link
Member

ajschmidt8 commented Feb 15, 2023

We can also just remove the autosectionlabel plugin to fix this issue. I'm not sure what effect that will have on the rendered docs.

I will check that locally.

@thomcom
Copy link
Contributor

thomcom commented Feb 15, 2023

I'd be interested in addressing the warnings in a follow up PR, we can chat about how to get my pre-commit set up to give me docs warnings in addition to the normal commit errors. Given that cuspatial.polygon_bounding_boxes is already defined in its own section, I'm ok with dropping that from the list of three functions under Indexed Spatial Joins.

@ajschmidt8
Copy link
Member

@thomcom, I just pushed two changes based on your reply.

Can you review / approve this PR when you have a moment? It should be good to go now.

@ajschmidt8
Copy link
Member

/merge

@rapids-bot rapids-bot bot merged commit 93fbc73 into rapidsai:branch-23.04 Feb 15, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
ci conda Related to conda and conda configuration improvement Improvement / enhancement to an existing function non-breaking Non-breaking change Python Related to Python code
Projects
Status: No status
Development

Successfully merging this pull request may close these issues.

4 participants