[devel at bb.net] Adding attribute to serialized objects
mariangemarcano at gmail.com
Tue Jan 26 09:04:13 UTC 2016
Do you know how we should handle adding an attribute to serialized object.
We are doing some customizations and we would like to add content_type to
class HTMLLogFile(styles.Versioned, LogFile):
so we increased the
persistenceVersion = 2
and added the
self.content_type = ''
self.wasUpgraded = True
But we got an error if we want to run buildbot on a different branch that
uses persistenceVersion = 1
the exception is thrown from this library
twisted/persisted/styles.py:400 in versionUpgrade
assert persistVers <= currentVers, "Sorry, can't go backwards in time."
Do you know how this should be handled?, it looks like we are missing/not
-------------- next part --------------
An HTML attachment was scrubbed...
More information about the devel