[
https://issues.apache.org/jira/browse/BEAM-2717?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=17221852#comment-17221852
]
Zhitao Li commented on BEAM-2717:
---------------------------------
I followed [~udim]'s suggestion and patched
[ProtoCoder]([https://github.com/apache/beam/blob/38feb03dd356912759dbceccb472657260fea629/sdks/python/apache_beam/coders/coders.py#L911])
by adding a trivial to_type_hint:
```
Class ProtoCoder:
...
def to_type_hint(self):
return self.proto_message_type
...
```
And this allows a TFX pipeline which uses ProtoCoder to work.
I wonder if such a quick workaround can be accepted, or its own flak?
> Infer coders in SDK prior to handing off pipeline to Runner
> -----------------------------------------------------------
>
> Key: BEAM-2717
> URL: https://issues.apache.org/jira/browse/BEAM-2717
> Project: Beam
> Issue Type: Bug
> Components: sdk-py-core
> Reporter: Robert Bradshaw
> Priority: P1
> Labels: types
> Time Spent: 3h 10m
> Remaining Estimate: 0h
>
> Currently all runners have to duplicate this work, and there's also a hack
> storing the element type rather than the coder in the Runner protos.
--
This message was sent by Atlassian Jira
(v8.3.4#803005)