[ARVADOS] created: 984de3071761b8db04fb47afacec9741b4fcfd98

Git user git at public.curoverse.com
Thu Mar 17 11:30:59 EDT 2016


        at  984de3071761b8db04fb47afacec9741b4fcfd98 (commit)


commit 984de3071761b8db04fb47afacec9741b4fcfd98
Author: Tom Clegg <tom at curoverse.com>
Date:   Thu Mar 10 15:25:41 2016 -0500

    8345: Do not crash when update() called without an obj.

diff --git a/services/fuse/arvados_fuse/fusefile.py b/services/fuse/arvados_fuse/fusefile.py
index e731327..3f0e493 100644
--- a/services/fuse/arvados_fuse/fusefile.py
+++ b/services/fuse/arvados_fuse/fusefile.py
@@ -95,6 +95,12 @@ class ObjectFile(StringFile):
         return self.object_uuid
 
     def update(self, obj=None):
+        if obj is None:
+            # TODO: retrieve the current record for self.object_uuid
+            # from the server. For now, at least don't crash when
+            # someone tells us it's a good time to update but doesn't
+            # pass us a fresh obj. See #8345
+            return
         self._mtime = convertTime(obj['modified_at']) if 'modified_at' in obj else 0
         self.contents = json.dumps(obj, indent=4, sort_keys=True) + "\n"
 

-----------------------------------------------------------------------


hooks/post-receive
-- 




More information about the arvados-commits mailing list