Please people, stop pulling the cable!!! You only risk breaking things!!! If you pull the wrong thing (wires), you will completely screw up your charge port (see post #60 above).
The cable releases the MECHANICAL lock pin so you can remove the charge cable in case of an electrical/electronics failure. It has nothing whatsoever to do with opening/closing the door of keeping it open.
Most of the time, the problem seems to resolve itself if you let the car lock and sleep with your phone/fob out of bluetooth range. If you must charge RIGHT NOW, open the door with the phone app/key fob if you have one while holding the charge handle in your other hand. Jam the handle in before the door closes, grimace at the grinding noises it makes when the door closes on the handle, and walk away with your phone/fob. It will likely be magically fixed when you return (if you wait long enough).
Really, don't yank on stuff behind the charge port. It doesn't help and just risks an expensive repair.