Okay, this is hard and I can’t wrap my head around it. My car has been through three thermostats and it’s still overheating. I replaced everything for the cooling system. Thermostat, water pump, expansion tank, upper/lower rad hose, radiator, fan clutch, belts and pulleys/ tensioner with the blue bmw coolant/ sensors. Not the one on the engine block though. After cooling system overhaul with genuine/OEM parts I had about 1000 miles of fine driving with my car overheated out in philly. I was near a friends and replaced the thermostat with one from the jyard and the car worked fine and got me home about 4 hours away. It was a motorad and 2018 date code on it. Before anyone asks why I didn’t get a new one none were in stock and I didn’t have the luxury of waiting for a new one to come in. Well about 2000 miles later my cooling light started going on and off then my car overheated after about 40 minutes of highway driving. Got it towed home and replaced it with another new Wahler thermostat. Car didn’t overheat and I drove it for about 40 minutes around town around 40-50 mph. Cooling light came on and off although. I bled the system again and it was off. Wouldn’t come on. Well after about 15 minutes off highway driving it was coming on and off and 25 minutes later the car overheated. After letting it cool down for 15 minutes I let it idle for jokes and drove it one minute and it didn’t overheat but cooling light was going on and off. No coolant leaks or anything. I am stumped. I know it’s possible to get defective parts but I’m totally lost at this point. I replaced everything in the engine besides the vanos refresh but that has nothing to do with cooling. Where do I go from here? I plan on a compression test but would a cracked cylinder head or bad head gasket be setting off the cooling light? No I don’t believe so and that doesn’t seem to be the issue at hand. I did check the thermostat fuse and noticed it was burnt around the edges of it and replaced it before leaving with another 20 amp fuse.