Polber commented on code in PR #30117:
URL: https://github.com/apache/beam/pull/30117#discussion_r1468061873


##########
sdks/python/apache_beam/yaml/yaml_provider.py:
##########
@@ -407,9 +427,11 @@ def fn_takes_side_inputs(fn):
 
 
 class InlineProvider(Provider):
-  def __init__(self, transform_factories, no_input_transforms=()):
+  def __init__(
+      self, transform_factories, no_input_transforms=(), 
custom_provider=False):

Review Comment:
   Since 'python' ExternalProviders use the `InlineProvider` under the hood 
when packages are not specified, I pass that flag to say that it is a "custom" 
provider (i.e. not built-in) so that the config callable values are evaluated 
upon transform creation. This way, the built-in transforms that already have a 
concept of 'callable' will not be interfered with.
   
   However, upon you bringing this up, I am now wondering if these callables 
for config values (excluding mapping transforms) should be evaluated in the 
preprocessing step instead of the `create_transform` step. I posted a question 
below about inconsistencies between these callables and the ones used by the 
mapping transforms. I think those questions should be resolved before possibly 
moving to preprocessing, but it could be a cleaner solution.



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