make sure examples close properly on failure