nursix/eden — pull request #19 by ptressel (2013-10-12 16:00:17+00:00)
Title: format was undefined so interpreted as built-in function format

(Copying over comments from abandoned pull request https://github.com/nursix/eden/pull/18 ...)

Was helping new user RK who asked about audit logs, so wanted to get some into the table. Turned on write audit, tried to add a supply_item, and got a ticket -- bad args to a lambda deep in dal represent. Turned out that S3SQLDefaultForm process() was not being passed "format" by S3SQLDefaultForm __call__ so "format" got interpreted as the built-in function format.

I just passed in format, but given that we're "supposed to" switch over to use the format function at some point (and, hey, supposed to go to Python 3 at some point...) maybe we should switch to fmt or something other than format? There are a lot of uses of "format"... Can change that if you want. Or should we sic one of our future interns on it? Or save it for GCI?

(Later comment:)

I should mention -- it got all the way through the prepop inserts and added audit records for those without hitting the format issue, so their code path may have been different. Since they didn't cause a problem, I didn't want to nuke my db again just to find out how they were different...