add some debugging to raven code