diff options
author | r3m0 <r3m0@38b22f21-9aea-0310-abfc-843a9883df58> | 2007-09-28 22:37:48 (GMT) |
---|---|---|
committer | r3m0 <r3m0@38b22f21-9aea-0310-abfc-843a9883df58> | 2007-09-28 22:37:48 (GMT) |
commit | 40f3e378f2cdb94206611aacdd09969098007b7a (patch) | |
tree | 0c6b9d0e030c09fc0761d9d2b54e5fddcf310c1c /twisted | |
parent | c5d85dc9dd61f7606795de6f26d211e664ca8270 (diff) |
recovery handling for even more old corrupt files
git-svn-id: https://exe.svn.sourceforge.net/svnroot/exe/trunk@3300 38b22f21-9aea-0310-abfc-843a9883df58
Diffstat (limited to 'twisted')
-rw-r--r-- | twisted/persisted/styles.py | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/twisted/persisted/styles.py b/twisted/persisted/styles.py index 8e3c24d..286ad51 100644 --- a/twisted/persisted/styles.py +++ b/twisted/persisted/styles.py @@ -330,7 +330,11 @@ class Versioned: + " as it no longer applies to any package.") elif repr(base) == "<class 'exe.engine.node.Node'>": - if newPackage is not None and self._package != newPackage: + # Note: some VERY old and corrupt packages have come in that + # don't even have the proper ._package attribute, nor ._id, + # or ._title, etc. So ensure that the node at least has that: + if hasattr(self, '_package') \ + and newPackage is not None and self._package != newPackage: # swap to a proper package on Nodes, IF the # current package is NOT the one that we're really using: if not mergeCheck: |