Improve debugging logs to show the context being passed into defstate
'in' and 'out' functions.