added some basic debugging functionality to the wrapper