A person does not have to be perfect to date, but a person does need to be in a fit mental state. Developing and maintaining a relationship requires the person to be able to focus on and prioritize the relationship and the person they seek to be in a relationship with.
Someone struggling with any real addiction, whether to alcohol, gambling or any substance or practice, needs to get on top of this issue before dating should begin. Likewise, someone who has a personality disorder, such as narcissism, obsessive-compulsive, or borderline personality, needs to get treatment to be in a position to pursue marriage.
If someone has a mental illness, such as clinical depression, generalized anxiety, or bipolar can in most cases successfully get back to a state of mental health. This is essential prior to dating, so that they can successfully pursue a relationship.