provide more information when logging setstate failures

More information on setstate failures would help debugging when there isn't enough information.  This includes the name of the class for which setstate failed, and how we got there.