Adding SWIG exception wrapping code so library exceptions don't kill the process with no stack trace