chamikaramj commented on a change in pull request #11185: [BEAM-8019] Updates
Python SDK to handle remote SDK coders and preserve tags added by remote SDKs
and propagate restriction coders.
URL: https://github.com/apache/beam/pull/11185#discussion_r400605401
##########
File path: sdks/python/apache_beam/runners/pipeline_context.py
##########
@@ -115,9 +115,12 @@ def get_id_to_proto_map(self):
# type: () -> Dict[str, message.Message]
return self._id_to_proto
- def put_proto(self, id, proto):
+ def get_proto_from_id(self, id):
+ return self.get_id_to_proto_map()[id]
+
+ def put_proto(self, id, proto, ignore_duplicates=False):
# type: (str, message.Message) -> str
- if id in self._id_to_proto:
+ if not ignore_duplicates and id in self._id_to_proto:
Review comment:
Done.
----------------------------------------------------------------
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:
[email protected]
With regards,
Apache Git Services