[ARVADOS] created: e399a43de926edcff6fb8383b2bc3b9b29db016b

git at public.curoverse.com git at public.curoverse.com
Thu Jan 21 13:37:25 EST 2016


        at  e399a43de926edcff6fb8383b2bc3b9b29db016b (commit)


commit e399a43de926edcff6fb8383b2bc3b9b29db016b
Author: Peter Amstutz <peter.amstutz at curoverse.com>
Date:   Thu Jan 21 13:37:20 2016 -0500

    7846: Better directory entry invalidation, fixes MagicDirApiError test.  Also
    fix bug in typo in exception handler.

diff --git a/services/fuse/arvados_fuse/__init__.py b/services/fuse/arvados_fuse/__init__.py
index 65f117b..eecd918 100644
--- a/services/fuse/arvados_fuse/__init__.py
+++ b/services/fuse/arvados_fuse/__init__.py
@@ -254,7 +254,7 @@ class Inodes(object):
         llfuse.invalidate_inode(inode)
 
     def invalidate_entry(self, inode, name):
-        llfuse.invalidate_entry(inode, name)
+        llfuse.invalidate_entry(inode, name.encode(self.encoding))
 
     def clear(self):
         self.inode_cache.clear()
diff --git a/services/fuse/arvados_fuse/fusedir.py b/services/fuse/arvados_fuse/fusedir.py
index 00efab7..86cfa52 100644
--- a/services/fuse/arvados_fuse/fusedir.py
+++ b/services/fuse/arvados_fuse/fusedir.py
@@ -442,6 +442,7 @@ class CollectionDirectory(CollectionDirectoryBase):
             _logger.exception("arv-mount %s: error", self.collection_locator)
             if self.collection_record is not None and "manifest_text" in self.collection_record:
                 _logger.error("arv-mount manifest_text is: %s", self.collection_record["manifest_text"])
+        self.invalidate()
         return False
 
     @use_counter
@@ -610,10 +611,11 @@ will appear if it exists.
                     self.inodes.del_entry(e)
                 return True
             else:
+                self.inodes.invalidate_entry(self.inode, k)
                 self.inodes.del_entry(e)
                 return False
-        except Exception as e:
-            _logger.debug('arv-mount exception keep %s', e)
+        except Exception as ex:
+            _logger.debug('arv-mount exception keep %s', ex)
             self.inodes.del_entry(e)
             return False
 

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


hooks/post-receive
-- 




More information about the arvados-commits mailing list