I am having trouble installing psycopg2. I get the following error when I try to pip install psycopg2
:
Error: pg_config executable not found.
P
On MacOS, the simplest solution will be to symlink the correct binary, that is under the Postgres package.
sudo ln -s /Applications/Postgres.app/Contents/Versions/latest/bin/pg_config /usr/local/bin/pg_config
This is fairly harmless, and all the applications will be able to use it system wide, if required.