FYI - I had the el cheapo ($9.98) Home Depot receptacle so cheap it was all one integrated plastic piece. We had the Tesla wall charger with NEMA 14-50 plug; also before we got that, used the portable charger that came with the Model 3. At one point the receptacle melted - oddly, in the same spot as the one in the photograph posted.
I replaced the plug with a new one, and then a few months later, the charger itself started dialing back, indicating the plug/feed wire from the NEMA socket was overheating. (from 40A or 32A dialed down to 15A) When charging, the power cord to the wall got too hot to touch. Telsa indicated that a Hubell 9450 was the preferred socket for a high-end application like charging, so I got one of those. (Does not fit a standard double box, had to get a slightly smaller square box - then wear out a grinder bit enlarging the hole to take a 1-1/4" conduit. )
Top end socket did not fix the problem (But I don't regret a quality socket) After further tests with the Tesla Service guy and Tesla, they determined the charger itself was defective. (Wonder why Tesla does not sell those any more?) They replaced it under warranty with a wall mount gen2. I got a NEMA14-50 power cord off Amazon.ca and hooked it up, rather than direct connect which would remove the NEMA 14-50 option. There is a GE power cord rated for 50A. The red and black are 6Ga, the neutral (white, not used) and ground (green) are 8Ga. Believe me, I made sure the whole assembly wires were firmly screwed down. I Set the Gen2 power (dial) to 40A. (The wiring to the socket is 50A breaker, 6Ga wire)
Since then, the socket box, plug, power cord, and feed to the car all remain cold to the touch at 40A continuous service. If ever the charger is a problem, I can use the portable one instead - plus I have an option to plug in any other high-power tools in my garage.
My first issue may have been "not tight enough" or it may be this sort of melt made the screw loose... Who knows. Yes, tighten everything firmly.