fix context call and debug messages from remarks code