dontpanic92 / wxGo

Golang wxWidgets Wrapper
Other
403 stars 51 forks source link

How do I capture a panic backtrace? #42

Closed axelniedenhoff closed 6 years ago

axelniedenhoff commented 6 years ago

I am probably missing something very obvious here… I have a wxGo application under Windows that simply vanishes at some point. I suspect that there is a panic somewhere, but I cannot see it. How can I capture the panic backtrace? (I saw in another issue here that this is apparently possible.)

dontpanic92 commented 6 years ago

I personally use the bash shell in MSYS2 which can get the error output by default. If you are using PowerShell, try .\test2.exe 2>&1 | echo

axelniedenhoff commented 6 years ago

I have checked the PowerShell approach. It works like a charm. Thank you!