robertwb commented on code in PR #33363:
URL: https://github.com/apache/beam/pull/33363#discussion_r1884704116
##########
sdks/python/apache_beam/coders/coders.py:
##########
@@ -1402,6 +1402,11 @@ def __hash__(self):
return hash(
(self.wrapped_value_coder, self.timestamp_coder, self.window_coder))
+ @classmethod
+ def from_type_hint(cls, typehint, registry):
+ # type: (Any, CoderRegistry) -> WindowedValueCoder
+ return cls(registry.get_coder(typehint.inner_type))
Review Comment:
Can you add a TODO to pass the right coder for the Window as well (so we
don't fall back to PickleCoder to encode the windows?) This would require
making TypedWindowedValue have two type parameters, the second being optional,
and might get messy, so can be deferred for now so we can get this in to
unbreak things.
--
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]