Only show stack trace when running in debug