Adding history module.
Adding email module. Now emailing on failure.