I think its more common than we realise.
I recently got locked in my car (not a Tesla) when the power went without warning. Windows, panroof and doors would not open when I'd just entered it. I had closed the door and boom everything shut off. I had to call fire brigade but within 40 minutes power came back and doors unlocked. It was the hottest day of the year and the car hadn't been used for best part of a week. I only had a few percent on my phone battery. I had visions of passing out in the heat and no one knowing I was there.
Luckily, I carry a glass hammer in the car with an integrated seatbet cutter. Once I realised I had that I calmed down and luckily didnt need to use it. Im getting everyone a glass hammer for Xmas, I really do think they should be standard in all cars.