13306: Updates ArvCwlExecutor to properly convert objects to JSON in unicode
authorEric Biagiotti <ebiagiotti@veritasgenetcs.com>
Tue, 15 Jan 2019 14:46:50 +0000 (09:46 -0500)
committerEric Biagiotti <ebiagiotti@veritasgenetcs.com>
Tue, 15 Jan 2019 14:46:50 +0000 (09:46 -0500)
commit07782f1743267638c996cb1d9bb3a85f24c8243e
tree5448f61b64a1711490e4d5544cb6a36a5857d0e7
parente17fe40c08651f39bc42468b1b2b56841bbaf223
13306: Updates ArvCwlExecutor to properly convert objects to JSON in unicode

json.dumps produces a str object in python 2 (bytestring) and a str object in python 3 (unicode), resulting in incompatibility when writing to the file (expects unicode). In order to prevent using py2 and py3 specific code, the solution is to call encode, which will force the string to be bytes in both languages, then decode to unicode from there.

Arvados-DCO-1.1-Signed-off-by:  Eric Biagiotti <ebiagiotti@veritasgenetics.com>
sdk/cwl/arvados_cwl/executor.py