You are viewing a plain text version of this content. The canonical link for it is here.
Posted to reviews@spark.apache.org by GitBox <gi...@apache.org> on 2020/10/20 01:09:21 UTC

[GitHub] [spark] HyukjinKwon commented on a change in pull request #30094: [SPARK-33003][PYTHON][DOCS] Add type hints guideliness to the documentation

HyukjinKwon commented on a change in pull request #30094:
URL: https://github.com/apache/spark/pull/30094#discussion_r508149218



##########
File path: python/docs/source/development/contributing.rst
##########
@@ -77,6 +77,43 @@ There are a couple of additional notes to keep in mind when contributing to code
 * Be Pythonic.
 * APIs are matched with Scala and Java sides in general.
 * PySpark specific APIs can still be considered as long as they are Pythonic and do not conflict with other existent APIs, for example, decorator usage of UDFs.
+* If you extend or modify public API, please adjust corresponding type hints. See `Contributing and Maintaining Type Hints`_ for details.
+
+Contributing and Maintaining Type Hints
+----------------------------------------
+
+PySpark type hints are provided using stub files, placed in the same directory as the annotated module, with exception to ``# type: ignore`` in modules which don't have their own stubs (tests, examples, non-public API).

Review comment:
       just a nit but maybe: `tests, examples, non-public API` -> `tests, examples and non-public API`?




----------------------------------------------------------------
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.

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



---------------------------------------------------------------------
To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org
For additional commands, e-mail: reviews-help@spark.apache.org