Faulty door switch did this to a previous Magna sedan I had. I can’t remember exactly but I think the door thought is was closed even though it was open.

Easy test turn your roof lights onto door setting and open and close each doo and if the light works correctly then it’s not a fault switch if the light doesn’t come on then the door is opened then the switch isn’t good.

Worth a shot and that’s all I can think of.