diff --git a/sdks/python/apache_beam/transforms/periodicsequence.py b/sdks/python/apache_beam/transforms/periodicsequence.py index 56075a5acc71..6127aa8de555 100644 --- a/sdks/python/apache_beam/transforms/periodicsequence.py +++ b/sdks/python/apache_beam/transforms/periodicsequence.py @@ -50,6 +50,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): '''