[Zope-Checkins] CVS: Products/AdaptableStorage/serial_ofs - UserFolderSerializer.py:1.2
Shane Hathaway
shane@zope.com
Tue, 7 Jan 2003 10:15:00 -0500
Update of /cvs-repository/Products/AdaptableStorage/serial_ofs
In directory cvs.zope.org:/tmp/cvs-serv26883/serial_ofs
Modified Files:
UserFolderSerializer.py
Log Message:
Fixed bugs:
- NameError in SQLUserList, fixed.
- FSUserList left lines alone that it didn't recognize, which looked
odd when pickles were involved. Now it removes unparseable lines when
writing.
- UserFolderSerializer wasn't adding all of the unmanaged persistent
objects to the event.
=== Products/AdaptableStorage/serial_ofs/UserFolderSerializer.py 1.1 => 1.2 ===
--- Products/AdaptableStorage/serial_ofs/UserFolderSerializer.py:1.1 Mon Jan 6 18:17:51 2003
+++ Products/AdaptableStorage/serial_ofs/UserFolderSerializer.py Tue Jan 7 10:14:27 2003
@@ -46,9 +46,11 @@
event.ignoreAttribute('data')
for id, user in object.data.items():
assert isinstance(user, User), repr(user)
+ assert len(user.__dict__.keys()) == 4, user.__dict__.keys()
state.append((id, user.__,
tuple(user.roles), tuple(user.domains)))
event.notifySerialized(id, user, 0)
+ event.addUnmanagedPersistentObjects([object.data])
event.addUnmanagedPersistentObjects(object.data.values())
return state
@@ -59,5 +61,6 @@
user = User(id, password, roles, domains)
object.data[id] = user
event.notifyDeserialized(id, user)
+ event.addUnmanagedPersistentObjects([object.data])
event.addUnmanagedPersistentObjects(object.data.values())