File tree 2 files changed +4
-0
lines changed
sdks/python/apache_beam/yaml
2 files changed +4
-0
lines changed Original file line number Diff line number Diff line change @@ -816,6 +816,9 @@ def split(element):
816
816
mapping_transform = mapping_transform .with_outputs (* output_set )
817
817
splits = pcoll | mapping_transform .with_input_types (T ).with_output_types (T )
818
818
result = {out : getattr (splits , out ) for out in output_set }
819
+ for tag , out in result .items ():
820
+ if tag != error_output :
821
+ out .element_type = pcoll .element_type
819
822
if error_output :
820
823
result [error_output ] = result [error_output ] | map_errors_to_standard_format (
821
824
pcoll .element_type )
Original file line number Diff line number Diff line change @@ -212,6 +212,7 @@ def test_partition(self):
212
212
language: python
213
213
outputs: [even, odd]
214
214
''' )
215
+ self .assertEqual (result ['even' ].element_type , elements .element_type )
215
216
assert_that (
216
217
result ['even' ] | beam .Map (lambda x : x .element ),
217
218
equal_to (['banana' , 'orange' ]),
You can’t perform that action at this time.
0 commit comments