Skip to content

Commit

Permalink
took out attempted multi-window input fix and replaced it with a desc…
Browse files Browse the repository at this point in the history
…riptive error message
  • Loading branch information
BjornPrime committed Dec 15, 2022
1 parent 2f754e9 commit d66a09a
Showing 1 changed file with 5 additions and 9 deletions.
14 changes: 5 additions & 9 deletions sdks/python/apache_beam/transforms/core.py
Original file line number Diff line number Diff line change
Expand Up @@ -2474,18 +2474,14 @@ def typed(transform):
# Capture in closure (avoiding capturing self).
args, kwargs = self.args, self.kwargs

#TODO: This is a short term fix but CombineGlobally() needs a more
# thorough effort to ensure it works with multi-window inputs consistently
#TODO: We need to add support for multi-window inputs to CombineGlobally()
def inject_default(_, combined):
if combined:
if len(combined) > 1:
_LOGGER.warning(
"Multiple simultaneous windows"
"aren't fully supported for CombineGlobally()")
fully_combined = []
for element in combined:
fully_combined.append(element)
return fully_combined
raise ValueError(
"Input from multiple simultaneous windows"
"isn't currently supported for CombineGlobally()")
return combined[0]
else:
try:
combine_fn.setup(*args, **kwargs)
Expand Down

0 comments on commit d66a09a

Please sign in to comment.