allow compute fields to depend on compute fields defined earlier

This commit is contained in:
Tim Richardson
2013-06-21 03:21:13 +10:00
parent e055c3af7e
commit 5dd452554e
+2
View File
@@ -8542,6 +8542,8 @@ class Table(object):
# try compute it
try:
new_fields[name] = (ofield,ofield.compute(row))
__,fields[name] = new_fields[name] #the value is the second element of the tuple
row = Row(fields) #allow later compute fields to refer to this value
except (KeyError, AttributeError):
# error sinlently unless field is required!
if ofield.required: