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

Unified Diff: tools/telemetry/telemetry/core/backends/chrome/inspector_backend.py

Issue 256843006: Get current tab url from requesting contexts. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: . Created 6 years, 8 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 | « no previous file | tools/telemetry/telemetry/core/tab_unittest.py » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: tools/telemetry/telemetry/core/backends/chrome/inspector_backend.py
diff --git a/tools/telemetry/telemetry/core/backends/chrome/inspector_backend.py b/tools/telemetry/telemetry/core/backends/chrome/inspector_backend.py
index dd627a3b692c9e5fd3c25353be28573e16f8c28f..5e242caf6e75e1aa37e665523b290ff743d2d10d 100644
--- a/tools/telemetry/telemetry/core/backends/chrome/inspector_backend.py
+++ b/tools/telemetry/telemetry/core/backends/chrome/inspector_backend.py
@@ -73,7 +73,10 @@ class InspectorBackend(inspector_websocket.InspectorWebsocket):
@property
def url(self):
- return self._context['url']
+ for c in self._browser_backend.ListInspectableContexts():
+ if c['id'] == self.id:
+ return c['url']
+ return None
@property
def id(self):
« no previous file with comments | « no previous file | tools/telemetry/telemetry/core/tab_unittest.py » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698