I'm probably one of the few commentors who has some direct experience with her situation (epilepsy and neurological condition). Not me personally but a family member.
On the one hand, I empathize because it is frustrating to feel useless and incapable. It's not just a work thing, that kind of condition makes every aspect of life difficult.
On the other, I have a hard time giving her 100% benefit of the doubt. In my experience, some people are not aware of their specific limitations, or don't respect them. This can lead to dangerous situations and other negative outcomes.
I can only assume French Labour laws and a degree of compassion is why they chose to keep her on payroll.
I don't consider her lucky. The people scoffing at her situation are representing themselves poorly.