You are viewing a plain text version of this content. The canonical link for it is here.
Posted to github@beam.apache.org by GitBox <gi...@apache.org> on 2022/06/14 21:33:07 UTC

[GitHub] [beam] TheNeuralBit commented on a diff in pull request #21861: Remove dataframe warnings from py38-docs logs

TheNeuralBit commented on code in PR #21861:
URL: https://github.com/apache/beam/pull/21861#discussion_r897340617


##########
sdks/python/scripts/generate_pydoc.sh:
##########
@@ -247,24 +247,28 @@ EOF
 
 # Build the documentation using sphinx
 # Reference: http://www.sphinx-doc.org/en/stable/man/sphinx-build.html
+# Note we cut out warnings from apache_beam.dataframe, this package uses pandas
+# documentation verbatim.
 python $(type -p sphinx-build) -v -a -E -q target/docs/source \
   target/docs/_build -c target/docs/source \
-  -w "target/docs/sphinx-build.warnings.log"
+  |& grep -E -v 'apache_beam\.dataframe.*WARNING:' \
+  |& tee "target/docs/sphinx-build.log"
 
 # Fail if there are errors or warnings in docs
-! grep -q "ERROR:" target/docs/sphinx-build.warnings.log || exit 1
-(! grep -v 'apache_beam.dataframe' target/docs/sphinx-build.warnings.log | grep -q "WARNING:") || exit 1

Review Comment:
   I added a comment above to explain it. The issue is that for the DataFrame API we copy docstrings verbatim from the equivalent pandas methods, and these have various issues that raise warnings in sphinx



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: github-unsubscribe@beam.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org