I came across this once. IIRC there have been several entries network=(...) in wpa_supplicant.conf. One outside RetroPie comment markers and one inside RetroPie comment markers (you can easily spot them when you open the file).
Remove the network=() outside the RetroPie markers and try again.
The config file is at /etc/wpa_supplicant/wpa_supplicant.conf
(Side node: You should have a country= setting in wpa_supplicant.conf in any case)