From: W. Trevor King Date: Wed, 2 Jun 2010 19:48:08 +0000 (-0400) Subject: Add FilePlaylist._ignored_keys for boring fields X-Git-Url: http://git.tremily.us/?a=commitdiff_plain;h=7c3829a0a04e68c5aa212017158fc48cc54d0372;p=hooke.git Add FilePlaylist._ignored_keys for boring fields --- diff --git a/hooke/playlist.py b/hooke/playlist.py index 59daa46..8efac47 100644 --- a/hooke/playlist.py +++ b/hooke/playlist.py @@ -122,6 +122,9 @@ class FilePlaylist (Playlist): super(FilePlaylist, self).__init__(drivers, name) self.set_path(path) self._digest = None + self._ignored_keys = [ + 'experiment', # class instance, not very exciting. + ] def set_path(self, path): if path != None: @@ -219,6 +222,8 @@ class FilePlaylist (Playlist): os.path.expanduser(self.path)))) curve_element.setAttribute('path', path) for key,value in curve.info.items(): + if key in self._ignored_keys: + continue curve_element.setAttribute(key, str(value)) string = doc.toprettyxml(encoding='utf-8') root.unlink() # break circular references for garbage collection