Index: gm/rebaseline_server/results.py |
diff --git a/gm/rebaseline_server/results.py b/gm/rebaseline_server/results.py |
index 11a7d6ecfdd7e9aa35a3e4d35185e207f7abcda0..b0027d22af3d19fd751217b067a0aa010cb2e784 100755 |
--- a/gm/rebaseline_server/results.py |
+++ b/gm/rebaseline_server/results.py |
@@ -213,7 +213,7 @@ class BaseComparisons(object): |
Raises: |
IOError if root does not refer to an existing directory |
""" |
- # I considered making this call _read_dicts_from_root(), but I decided |
+ # I considered making this call read_dicts_from_root(), but I decided |
# it was better to prune out the ignored builders within the os.walk(). |
if not os.path.isdir(root): |
raise IOError('no directory found at path %s' % root) |
@@ -227,9 +227,13 @@ class BaseComparisons(object): |
meta_dict[builder] = gm_json.LoadFromFile(full_path) |
return meta_dict |
- def _read_dicts_from_root(self, root, pattern='*.json'): |
+ @staticmethod |
+ def read_dicts_from_root(root, pattern='*.json'): |
"""Read all JSON dictionaries within a directory tree. |
+ TODO(stephana): Factor this out into a utility module, as a standalone |
+ function (not part of a class). |
+ |
Args: |
root: path to root of directory tree |
pattern: which files to read within root (fnmatch-style pattern) |