diff --git a/sdks/python/apache_beam/transforms/periodicsequence.py b/sdks/python/apache_beam/transforms/periodicsequence.py index 0417224c6479..b2d7b375571b 100644 --- a/sdks/python/apache_beam/transforms/periodicsequence.py +++ b/sdks/python/apache_beam/transforms/periodicsequence.py @@ -51,6 +51,10 @@ def create_tracker(self, restriction): def restriction_size(self, unused_element, restriction): return restriction.size() + # On drain, immediately stop emitting new elements + def truncate(self, unused_element, unused_restriction): + return None + class ImpulseSeqGenDoFn(beam.DoFn): '''