Single error handler

Addresses #154, replaces #160.

@zeke please review; do your worst :see_no_evil: