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

Unified Diff: dashboard/dashboard/pinpoint/models/quest_generator.py

Issue 3001043002: [pinpoint] Add ReadGraphJsonValue. (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
Index: dashboard/dashboard/pinpoint/models/quest_generator.py
diff --git a/dashboard/dashboard/pinpoint/models/quest_generator.py b/dashboard/dashboard/pinpoint/models/quest_generator.py
index a6db82e8c942790e64b5f8799ae72377e0740ace..e4b6dcf86d8a241fd1c8efab719c2e197a1bf679 100644
--- a/dashboard/dashboard/pinpoint/models/quest_generator.py
+++ b/dashboard/dashboard/pinpoint/models/quest_generator.py
@@ -39,6 +39,7 @@ class TelemetryQuestGenerator(object):
def __init__(self, request):
self.configuration = request.get('configuration')
+ self.target = request.get('target')
self.dimensions = request.get('dimensions')
# TODO: Use the correct browser for Android and 64-bit Windows.
self.browser = 'release'
@@ -54,13 +55,16 @@ class TelemetryQuestGenerator(object):
if not self.configuration:
raise TypeError('Missing "configuration" argument.')
+ if not self.target:
+ raise TypeError('Missing "target" argument.')
+
if self.dimensions:
self.dimensions = json.loads(self.dimensions)
if not self.benchmark:
raise TypeError('Missing "benchmark" argument.')
def Quests(self):
- quests = [quest_module.FindIsolate(self.configuration)]
+ quests = [quest_module.FindIsolate(self.configuration, self.target)]
if not self.dimensions:
return quests
@@ -76,8 +80,9 @@ class TelemetryQuestGenerator(object):
def AsDict(self):
return {
- 'dimensions': self.dimensions,
'configuration': self.configuration,
+ 'target': self.target,
+ 'dimensions': self.dimensions,
'browser': self.browser,
'benchmark': self.benchmark,
'story': self.story,

Powered by Google App Engine
This is Rietveld 408576698