damccorm commented on code in PR #28205:
URL: https://github.com/apache/beam/pull/28205#discussion_r1309323439


##########
sdks/python/apache_beam/ml/transforms/tft.py:
##########
@@ -68,6 +68,15 @@
 _LOGGER = logging.getLogger(__name__)
 
 
+def warn_about_consistent_artifact_output(
+    cls_name: str, artifacts_name: List[str]):
+  _LOGGER.warning(
+      "The outputs of the get_artifacts method of class %s" % cls_name +
+      " are computed over the "
+      "entire dataset. For each transformed element, the corresponding "
+      "artifacts %s will be the same." % artifacts_name)

Review Comment:
   I don't think this is the right way to communicate this information, I think 
this should be part of our documentation. Warnings are a sign that something 
may be wrong, and in almost all cases should be something that the user can 
suppress or get rid of by doing some "right" thing; otherwise you end up with 
code where warnings are no longer useful signals.
   
   I could maybe get behind an info log here, but I'd prefer we just:
   1) Add this behavior to the pydoc
   2) Add it to the documentation in a FAQ/troubleshooting section



-- 
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: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]

Reply via email to