How to find Wi-Fi password when it's not saved in the keychain but Mac automatically connects to it

To exclude a malfunction of Keychain Access.app, you could try the security command in Terminal (to be found in /Applications/Utilities/, or search with Spotlight):

security find-generic-password -D "AirPort network password" -l "network name" -w

Replace "network name" (without the quotes) with the wireless network's actual name.
Hit enter and a window will pop up and ask for administrator credentials.
Enter those and click "Allow" to find the password as output in Terminal.