TheNeuralBit commented on a change in pull request #12324:
URL: https://github.com/apache/beam/pull/12324#discussion_r458305914
##########
File path: sdks/python/apache_beam/coders/standard_coders_test.py
##########
@@ -81,7 +81,10 @@ def attribute_parser_from_type(type_):
# TODO: This should be exhaustive
type_info = type_.WhichOneof("type_info")
if type_info == "atomic_type":
- return schemas.ATOMIC_TYPE_TO_PRIMITIVE[type_.atomic_type]
+ if type_.atomic_type == schema_pb2.BYTES:
+ return lambda x: x.encode("utf-8")
Review comment:
That's right. This is basically the same as the logic here:
https://github.com/apache/beam/blob/3b0ba733dc3d9b063b3fff9297073f26c06e8a0d/sdks/python/apache_beam/coders/standard_coders_test.py#L118-L121
I have a TODO in the code to unify these paths but haven't gotten around to
it yet.
----------------------------------------------------------------
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]