Fix bug in spawning with attributes

This commit is contained in:
Griatch 2018-10-06 19:05:57 +02:00
parent dd7ed22019
commit d444820036

View file

@ -733,8 +733,9 @@ def spawn(*prototypes, **kwargs):
val = make_iter(prot.pop("attrs", []))
attributes = []
for (attrname, value, category, locks) in val:
attributes.append((attrname, init_spawn_value(val), category, locks))
attributes.append((attrname, init_spawn_value(value), category, locks))
print("attributes to spawn: IN: {}, OUT: {}".format(val, attributes))
simple_attributes = []
for key, value in ((key, value) for key, value in prot.items()
if not (key.startswith("ndb_"))):