Exception stuff

Start made on throwing nice exceptions that log possibly useful info
to the log file.