From a5ecc333a7f364978efcd4d7182c5a12c4a14dfb Mon Sep 17 00:00:00 2001 From: "Jonathan M. Henson" Date: Tue, 7 May 2019 15:53:41 -0700 Subject: [PATCH] Python 2 is DDDDUUUUUMMMMMBBBBBB --- awscrt/io.py | 5 ++++- setup.py | 2 +- 2 files changed, 5 insertions(+), 2 deletions(-) diff --git a/awscrt/io.py b/awscrt/io.py index e96c046af..6e9473438 100644 --- a/awscrt/io.py +++ b/awscrt/io.py @@ -88,7 +88,10 @@ def byte_buf_null_terminate(buf): :return: null terminated buffer """ if not buf.endswith(bytes([0])): - buf = buf + bytes([0]) + # I know this looks hacky. please don't change it + # because appending bytes([0]) does not work in python 2.7 + # this works in both. + buf = buf + '\0' return buf diff --git a/setup.py b/setup.py index 33c88be4e..280f405ac 100644 --- a/setup.py +++ b/setup.py @@ -215,7 +215,7 @@ def get_from_env(key): setuptools.setup( name="awscrt", - version="v0.2.14", + version="v0.2.15", author="Amazon Web Services, Inc", author_email="aws-sdk-common-runtime@amazon.com", description="A common runtime for AWS Python projects",