Just had this problem on my 2015 S P90D on the left rear side. I found this thread AFTER figuring out how to fix it. I thought it was the sunroof drain at first but noticed all water poured into drain made its way out to rear wheel well. I took all the interior trim and panels off the left rear and pulled down the corner of the roof material to pinpoint the leak. I noticed that the chrome had a decent gap except in the area where the headliner was wet. In that area the chrome had virtually no gap between chrome and the paint which keeps water from flowing down the chrome channel. I realized that at that point when I poured water in that area it came straight through. Every drop! Unreal for a 5 year old luxury vehicle. I could see exactly where the water poured in and it was near the bolt that holds either the chrome or window frame in place. Went to hardware store and got some “Flex Shot” which is the caulk version of the Flex Seal stuff. I filled the area that was leaking and waited 30 minutes for curing. Poured water and it came in a little ways down from the original spot so I ended up applying the Flex Shot along the entire seam which ran to the very back of the small window. Pics included to show where water was dripping, where the chrome had no gap for water to flow, where I first applied the flex shot and where I applied the entire length. $12 fix instead of the $1500 it seems Tesla would have charged.
View attachment 512631