add lots of logging