Stacktrace and debug output to see what's going wrong