apache / apache/beam

Serialization issue with non-bool 'streaming' value

Open
#19,127 0 comments 0 reactions 0 assignees View on GitHub
bug dataflow harness P3 python runners
Dominant language
Java
Stars
8.7k
Forks
4.7k
Avg merge
1d 20h
Merged PRs (30d)
196

Description

Hi all,

Just want to start out with that this was my own fault and I'm only reporting because it took me a while to figure out and the library could prevent it.

I'm using the python 2.8.0 beam library pushing to Google dataflow.

Based on the options that were presented to the application I set streaming or not like:

    streaming = options.topic or options.subscription
    options.view_as(StandardOptions).streaming = streaming

This was working fine with the direct runner, but when i push to dataflow the container wasn't starting. In python (str or str) is a string, which works great for truth-y ness and local dev, but at some point we serialize this value and send it to dataflow which tries to deserialize this string as a boolean and the harness crashes.

Anyway, my fault, however if we're serializing values that are going to be decoded by golang it'd be nice to be stricter about this on the client side as it's easy to screw up.

Thanks for your help.

Imported from Jira [BEAM-6121](https://issues.apache.org/jira/browse/BEAM-6121). Original Jira may contain additional context.
Reported by: jamielennox.

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.