modifying now state handler which also stores history
writing election safety conditions and adding check_safety to simulator