before we expose a sqlalchemy object to the xmlrpc wire, we need to
authorThierry Parmentelat <thierry.parmentelat@inria.fr>
Tue, 25 Sep 2012 14:24:18 +0000 (16:24 +0200)
committerThierry Parmentelat <thierry.parmentelat@inria.fr>
Tue, 25 Sep 2012 14:24:18 +0000 (16:24 +0200)
commitaee483d12ec71493fa02f9cf6752e50ee4a28f7c
treee716bbc3348fe484a57fb8504218fe8a938c400f
parent200cb20896e5b7fc2fa1e3b0f48ce71faad7608d
before we expose a sqlalchemy object to the xmlrpc wire, we need to
clean up related objects - xmlrpc would not allow it, we expose hrns
instead anyways
the way we did this before this change was to look for lists of
RegRecord or RegKey
however it turns out the lists are actually instances of
sqlalchemy.orm.collections.InstrumentedList
so if a list turns out empty, it did not get filter out but could not
get marshalled either
we simplify the code for filtering out (Record.todict) to exclude
objects only on the value type (not its sons when it's a list)
and the manager does not pass RegRecord or RegKey anymore, but just
InstrmentedList
sfa/managers/registry_manager.py
sfa/storage/record.py