chadrik commented on a change in pull request #12881:
URL: https://github.com/apache/beam/pull/12881#discussion_r491595091
##########
File path: sdks/python/apache_beam/runners/worker/bundle_processor.py
##########
@@ -705,10 +713,11 @@ def __init__(self,
self._key_coder = key_coder
self._window_coder = window_coder
# A mapping of {timer_family_id: TimerInfo}
- self._timers_info = {}
- self._all_states = {} # type: Dict[tuple, userstate.RuntimeState]
+ self._timers_info = {} # type: Dict[str, TimerInfo]
+ self._all_states = {} # type: Dict[tuple, FnApiUserRuntimeStateTypes]
Review comment:
`userstate.RuntimeState` does not have the necessary `commit()` method,
and there is no common base class for these 4 types that has all of the
necessary methods. When dealing with a reasonably limited number of
possibilities with unclear parentage, a `Union` is a good 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.
For queries about this service, please contact Infrastructure at:
[email protected]