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

Unified Diff: chrome/common/extensions/docs/server2/github_file_system.py

Issue 10871002: Extensions Docs Server: Testing GithubFileSystem and cron jobs (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 8 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: chrome/common/extensions/docs/server2/github_file_system.py
diff --git a/chrome/common/extensions/docs/server2/github_file_system.py b/chrome/common/extensions/docs/server2/github_file_system.py
index b518b202d5e7e442fdf9667f922cbaf22156c722..f4c7ae4229d745c65ec891e59263702c739891ce 100644
--- a/chrome/common/extensions/docs/server2/github_file_system.py
+++ b/chrome/common/extensions/docs/server2/github_file_system.py
@@ -29,8 +29,9 @@ class _AsyncFetchFutureZip(object):
self._blobstore.Set(_MakeKey(self._new_version),
blob,
blobstore.BLOBSTORE_GITHUB)
- self._blobstore.Delete(_MakeKey(self._old_version),
- blobstore.BLOBSTORE_GITHUB)
+ if self._old_version != self._new_version:
not at google - send to devlin 2012/08/22 13:57:58 This "old version" vs "new version" thing is a bit
cduvall 2012/08/22 17:20:43 Done.
+ self._blobstore.Delete(_MakeKey(self._old_version),
+ blobstore.BLOBSTORE_GITHUB)
return ZipFile(BytesIO(blob))
class GithubFileSystem(FileSystem):
@@ -82,7 +83,7 @@ class GithubFileSystem(FileSystem):
return Future(value=result)
def Stat(self, path):
- version = self._object_store.Get(path, object_store.GITHUB_STAT)
+ version = self._object_store.Get(path, object_store.GITHUB_STAT).Get()
if version is not None:
return StatInfo(version)
version = json.loads(

Powered by Google App Engine
This is Rietveld 408576698