Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(612)

Unified Diff: tracing/tracing/value/add_revision_info.py

Issue 2999663002: Revert of Revision Info into GenericSet (Closed)
Patch Set: Created 3 years, 4 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « tracing/trace_viewer.gypi ('k') | tracing/tracing/value/diagnostics/all_diagnostics.html » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: tracing/tracing/value/add_revision_info.py
diff --git a/tracing/tracing/value/add_revision_info.py b/tracing/tracing/value/add_revision_info.py
new file mode 100644
index 0000000000000000000000000000000000000000..e4f40631c8fd9a083095868ff134e0dec8c69427
--- /dev/null
+++ b/tracing/tracing/value/add_revision_info.py
@@ -0,0 +1,24 @@
+# Copyright 2016 The Chromium Authors. All rights reserved.
+# Use of this source code is governed by a BSD-style license that can be
+# found in the LICENSE file.
+
+import json
+import tempfile
+
+from tracing.value import add_shared_diagnostic
+
+def AddRevisionInfo(histograms_json_filename, chromium, v8, catapult, angle,
+ skia, webrtc):
+ revision_info = {
+ 'chromium': chromium,
+ 'v8': v8,
+ 'catapult': catapult,
+ 'angle': angle,
+ 'skia': skia,
+ 'webrtc': webrtc,
+ }
+
+ with tempfile.NamedTemporaryFile() as diagnostic_file:
+ json.dump(revision_info, diagnostic_file)
+ return add_shared_diagnostic.AddSharedDiagnostic(
+ histograms_json_filename, 'revisions', diagnostic_file.name)
« no previous file with comments | « tracing/trace_viewer.gypi ('k') | tracing/tracing/value/diagnostics/all_diagnostics.html » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698