Thursday, 11 June 2009

Poker Copilot's Crash Reporter

Let's say that double-clicking on Poker Copilot's "Position Summary" screen crashes Poker Copilot one time in 100. To find this bug, I'd have to use the screen a lot. Many times to cause the bug, and many times more to reproduce the bug. But if 100 people used the Position Summary screen in one day, chances are that the bug would rear its head at least once most days.

To help track down some obscure issues like this, I added a Crash Reporter to Poker Copilot 2 a couple of weeks ago. If Poker Copilot crashes, the Crash Reporter springs to life, notifying the user, and offering them a chance to send the crash report to Poker Copilot international headquarters. Location: my home office.

The crash report sends the error message plus a snapshot of the state of Poker Copilot. (For the techies: a stack trace and thread dump, plus assorted system properties.)

I'm now getting several crash reports a day, and lordy me, are they ever helpful. That hypothetical once-in-a-100-times bug I described above? It wasn't hypothetical at all. It was very real, and with the help of crash reports I mercilessly murdered it.

8 comments:

Anonymous said...

My little snitch
http://www.obdev.at/products/littlesnitch/index.html
shows me a couple different place PC connects to. maybe one day you could go into some detail.

Anonymous said...

The Crash Reporter - the only feature of copilot 2 I am actually able to use. ;(

Anonymous said...

"The Crash Reporter - the only feature of copilot 2 I am actually able to use. ;("

Haha! Mine crashes as soon as I turn on the HUD. It looks great though and I can't wait to get a working version.

Steve, any plans to support HORSE? PCP is completely befuddled by PStars cash and tourney HORSE games. I can send some HHs if it will help.

Anonymous said...

Did you use a 3rd party framework for this, or did you roll your own?

Steve McLeod said...

I rolled my own crash reporter.

No plans to support HORSE yet...

Orthene said...

Could you provide any tips on how you wrote your crash reporter? Does it just send stack traces to you, or is there more information from key data structures?

Steve McLeod said...

@Orthene

If you know something about Java, here's what we send:

* Thread.getAllStackTraces()
* System.getProperties()
* Some additional Poker Copilot specific properties, such as version and hand history folders

Orthene said...

Thanks! I had never run into that method, that'll be a big help.

Poker Copilot for Mac OS X helps
online poker players improve their game with easy-to-interpret
statistics and real-time analysis.

Optimise your poker game immediately with simple, understandable graphs and tables created from your hand history.