I had the same issue when using docker on my mac running both pgAdmin and postgres on localhost. Solution for me was to use the container name as my host name in pgAdmin. Apparently pgAdmin is not able to resolve localhost to the correct container.