Print explicitly to stdout to ensure script actually works.
I think it works, just want to make sure (and I think it's good to
print something for the build step).
Bug: chromium:1029452
Change-Id: I8df6818a2fb6305b688ae4ae7517159d1ca5b544
Reviewed-on: https://webrtc-review.googlesource.com/c/src/+/168602
Reviewed-by: Mirko Bonadei <mbonadei@webrtc.org>
Commit-Queue: Patrik Höglund <phoglund@google.com>
Cr-Commit-Position: refs/heads/master@{#30528}
diff --git a/tools_webrtc/perf/webrtc_dashboard_upload.py b/tools_webrtc/perf/webrtc_dashboard_upload.py
index 67729d0..35784f8 100644
--- a/tools_webrtc/perf/webrtc_dashboard_upload.py
+++ b/tools_webrtc/perf/webrtc_dashboard_upload.py
@@ -79,6 +79,8 @@
else:
data = zlib.compress(serialized)
+ print 'Sending %d bytes to %s.' % (len(data), url + '/add_histograms')
+
http = httplib2.Http()
response, content = http.request(url + '/add_histograms', method='POST',
body=data, headers=headers)
@@ -180,9 +182,10 @@
options.dashboard_url, histograms, oauth_token)
if response.status == 200:
+ print 'Received 200 from dashboard.'
return 0
else:
- print("Upload failed with %d: %s\n\n%s" % (response.status, response.reason,
+ print('Upload failed with %d: %s\n\n%s' % (response.status, response.reason,
content))
return 1