From 9af11905c4f926903372de9c1eee69406d70431f Mon Sep 17 00:00:00 2001 From: aiolos Date: Mon, 11 May 2015 02:10:35 -0700 Subject: [PATCH] Remove wpr.archive_info dependancy on page to avoid circular dependancies. importing page.page_test currently causes a circular dependency unless story is imported first. BUG=486276 Review URL: https://codereview.chromium.org/1133973002 Cr-Commit-Position: refs/heads/master@{#329126} --- tools/telemetry/telemetry/wpr/archive_info.py | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/tools/telemetry/telemetry/wpr/archive_info.py b/tools/telemetry/telemetry/wpr/archive_info.py index 3468ed1e775f..e7a8bb4375aa 100644 --- a/tools/telemetry/telemetry/wpr/archive_info.py +++ b/tools/telemetry/telemetry/wpr/archive_info.py @@ -9,7 +9,6 @@ import re import shutil import tempfile -from telemetry import page as page_module from telemetry.util import cloud_storage @@ -102,7 +101,7 @@ class WprArchiveInfo(object): if self.temp_target_wpr_file_path: return self.temp_target_wpr_file_path wpr_file = self._user_story_name_to_wpr_file.get(story.display_name, None) - if wpr_file is None and isinstance(story, page_module.Page): + if wpr_file is None and hasattr(story, 'url'): # Some old pages always use the URL to identify a page rather than the # display_name, so try to look for that. wpr_file = self._user_story_name_to_wpr_file.get(story.url, None) -- 2.11.4.GIT