From cb7184549d43d7a1cb80df4641760cb92505672b Mon Sep 17 00:00:00 2001 From: Adam Coldrick Date: Tue, 14 Apr 2015 14:08:09 +0000 Subject: fixup: Fix local-artifact-cache list-all --- morphlib/localartifactcache.py | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) (limited to 'morphlib') diff --git a/morphlib/localartifactcache.py b/morphlib/localartifactcache.py index e6695c4e..9e3c9e70 100644 --- a/morphlib/localartifactcache.py +++ b/morphlib/localartifactcache.py @@ -132,8 +132,9 @@ class LocalArtifactCache(object): CacheInfo = collections.namedtuple('CacheInfo', ('artifacts', 'mtime')) contents = collections.defaultdict(lambda: CacheInfo(set(), 0)) for filename in self.cachefs.walkfiles(): - cachekey = filename[:63] - artifact = filename[65:] + if filename.startswith('/repo'): # pragma: no cover + continue + cachekey, artifact = filename.split('.', 1) artifacts, max_mtime = contents[cachekey] artifacts.add(artifact) art_info = self.cachefs.getinfo(filename) -- cgit v1.2.1