There is a corner case not covered in the "adjust_subtable" that I only picked up because of a very old mod. For some reason the author decided to name the "amount" field but not the "item" field in the result tables. "adjust_subtable" only checks whether or not the "item" field is named and then assumes that the "amount" is the same. If the "amount" field is present when "adjust_subtable" assumes it isn't, Factorio crashes with an error about type conversion.
Changing the top if block in "adjust_subtable" to the following fixes the issue.
if not item.name then -- shift to uniform format for ease of handling
item.name = item[1]
item.type = "item"
item[1] = nil
end
if not item.amount then
item.amount = item[2]
item[2] = nil
end
No other mods that I am aware of specify their results tables this way so this shouldn't be critical to fix.