summaryrefslogtreecommitdiff
path: root/distbuild/build_controller.py
diff options
context:
space:
mode:
authorLars Wirzenius <lars.wirzenius@codethink.co.uk>2014-07-15 12:23:49 +0000
committerLars Wirzenius <lars.wirzenius@codethink.co.uk>2014-07-15 12:23:49 +0000
commite8adedb8f3f27d9212caf277b8e8f7c6792a20c2 (patch)
treef8460c9ff73cea780d944f18d1bab49f2653b1cf /distbuild/build_controller.py
parent3f686a074fdb66e75e67e276d21bdc604b34920c (diff)
parent40a5c752de62dd1b3ef3ec0850f1f24e7af67052 (diff)
downloadmorph-e8adedb8f3f27d9212caf277b8e8f7c6792a20c2.tar.gz
Fix JSON file handling to be binary filename safe
Reviewed-by: Lars Wirzenius Reviewed-by: Pedro Alvarez
Diffstat (limited to 'distbuild/build_controller.py')
-rw-r--r--distbuild/build_controller.py4
1 files changed, 2 insertions, 2 deletions
diff --git a/distbuild/build_controller.py b/distbuild/build_controller.py
index 987f01f4..e0aec24e 100644
--- a/distbuild/build_controller.py
+++ b/distbuild/build_controller.py
@@ -340,7 +340,7 @@ class BuildController(distbuild.StateMachine):
id=self._helper_id,
url=url,
headers={'Content-type': 'application/json'},
- body=json.dumps(artifact_names),
+ body=json.dumps(artifact_names, encoding='unicode-escape'),
method='POST')
request = distbuild.HelperRequest(msg)
@@ -369,7 +369,7 @@ class BuildController(distbuild.StateMachine):
_AnnotationFailed(http_status_code, error_msg))
return
- cache_state = json.loads(event.msg['body'])
+ cache_state = json.loads(event.msg['body'], encoding='unicode-escape')
map_build_graph(self._artifact, set_status)
self.mainloop.queue_event(self, _Annotated())