[Yt-svn] yt-commit r1106 - trunk/yt/lagos

britton at wrangler.dreamhost.com britton at wrangler.dreamhost.com
Mon Jan 12 13:25:29 PST 2009


Author: britton
Date: Mon Jan 12 13:25:29 2009
New Revision: 1106
URL: http://yt.spacepope.org/changeset/1106

Log:
Fixed bug in if statement controlling whether the yt file should be opened as 
read only or append.


Modified:
   trunk/yt/lagos/HierarchyType.py

Modified: trunk/yt/lagos/HierarchyType.py
==============================================================================
--- trunk/yt/lagos/HierarchyType.py	(original)
+++ trunk/yt/lagos/HierarchyType.py	Mon Jan 12 13:25:29 2009
@@ -114,8 +114,8 @@
         else:
             fn = os.path.join(self.directory,
                     "%s.yt" % self.parameter_file.basename)
-        if ytcfg.getboolean('lagos','onlydeserialize') and \
-           os.access(fn, os.W_OK):
+        if ytcfg.getboolean('lagos','onlydeserialize') or \
+           not os.access(fn, os.W_OK):
             self._data_mode = mode = 'r'
         else:
             self._data_mode = mode = 'a'



More information about the yt-svn mailing list