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

Remove warnings in documentation #2097

Merged
merged 15 commits into from Apr 6, 2021
Merged

Remove warnings in documentation #2097

merged 15 commits into from Apr 6, 2021

Conversation

bchen1116
Copy link
Contributor

@bchen1116 bchen1116 commented Apr 6, 2021

fix #2011
testing to clean up documentation code
Before:
image

After:
image

@bchen1116 bchen1116 self-assigned this Apr 6, 2021
@codecov
Copy link

codecov bot commented Apr 6, 2021

Codecov Report

Merging #2097 (c663650) into main (eb19b68) will not change coverage.
The diff coverage is n/a.

Impacted file tree graph

@@           Coverage Diff           @@
##             main    #2097   +/-   ##
=======================================
  Coverage   100.0%   100.0%           
=======================================
  Files         288      288           
  Lines       23419    23419           
=======================================
  Hits        23409    23409           
  Misses         10       10           

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update eb19b68...c663650. Read the comment docs.

@bchen1116 bchen1116 changed the title [TEST] Remove warnings in documentation Remove warnings in documentation Apr 6, 2021
@bchen1116 bchen1116 marked this pull request as ready for review April 6, 2021 19:34
Copy link
Contributor

@jeremyliweishih jeremyliweishih left a comment

Choose a reason for hiding this comment

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

nice and clean 😄

Copy link
Contributor

@angela97lin angela97lin left a comment

Choose a reason for hiding this comment

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

LGTM! Just left one comment about whether we should filter all warnings, or just DeprecationWarnings. Okay to leave out of scope though, but could be good to file.

@@ -0,0 +1,2 @@
import warnings
warnings.filterwarnings('ignore')
Copy link
Contributor

Choose a reason for hiding this comment

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

Just thinking out loud... do we want to disable all warnings? Is it possible to disable just DeprecationWarnings? I know warnings in the past have been useful in showing where some things are not as we expected, could be out of scope for this PR though.

Copy link
Contributor

Choose a reason for hiding this comment

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

Agree on the idea but I also think it's best suited for a different PR. We'll have to modify deprecate_arg to issue a DeprecationWarning for starters which, although is a small change, seems out of scope for this PR. I think the intent was a refactor without changing behavior.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Great idea! Filed a new issue here

Copy link
Contributor

@freddyaboulton freddyaboulton left a comment

Choose a reason for hiding this comment

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

Cool solution @bchen1116! Looks good to me.

@@ -261,6 +263,8 @@ class AccessorMethodDocumenter(AccessorLevelDocumenter, MethodDocumenter):


def setup(app):
os.makedirs("/home/docs/.ipython/profile_default/startup")
shutil.copy("disable-warnings.py", "/home/docs/.ipython/profile_default/startup/")
Copy link
Contributor

Choose a reason for hiding this comment

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

They let you run arbitrary code on start-up? 😨

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Yep, apparently! This is what the support team suggested

Copy link
Contributor

Choose a reason for hiding this comment

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

Let the evil commence!

@bchen1116 bchen1116 merged commit 59f6433 into main Apr 6, 2021
@chukarsten chukarsten mentioned this pull request Apr 6, 2021
@freddyaboulton freddyaboulton deleted the bc_test_jupyter_doc branch May 13, 2022 15:18
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.

Find simpler implementation to address warnings in documentation
4 participants