Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Installing psycopg2-binary 2.8.6 complains about missing pg_config #1166

Closed
felfert opened this issue Oct 12, 2020 · 3 comments
Closed

Installing psycopg2-binary 2.8.6 complains about missing pg_config #1166

felfert opened this issue Oct 12, 2020 · 3 comments

Comments

@felfert
Copy link

felfert commented Oct 12, 2020

running pip install psycopg2-binary

Produces the following error:

running egg_info
    creating C:\Users\cloudbase-init\AppData\Local\Temp\pip-pip-egg-info-2rqomfrb\psycopg2_binary.egg-info
    writing C:\Users\cloudbase-init\AppData\Local\Temp\pip-pip-egg-info-2rqomfrb\psycopg2_binary.egg-info\PKG-INFO
    writing dependency_links to 
C:\Users\cloudbase-init\AppData\Local\Temp\pip-pip-egg-info-2rqomfrb\psycopg2_binary.egg-info\dependency_links.txt
    writing top-level names to 
C:\Users\cloudbase-init\AppData\Local\Temp\pip-pip-egg-info-2rqomfrb\psycopg2_binary.egg-info\top_level.txt
    writing manifest file 
'C:\Users\cloudbase-init\AppData\Local\Temp\pip-pip-egg-info-2rqomfrb\psycopg2_binary.egg-info\SOURCES.txt'
    
    Error: pg_config executable not found.
    
    pg_config is required to build psycopg2 from source.  Please add the directory
    containing pg_config to the $PATH or specify the full executable path with the
    option:
    
        python setup.py build_ext --pg-config /path/to/pg_config build ...
    
    or with the pg_config option in 'setup.cfg'.
    
    If you prefer to avoid building psycopg2 from source, please install the PyPI
    'psycopg2-binary' package instead.
    

If I'm understanding the doc correctly, that should only happen when installing psycopg2, not psycopg2-binary

Cheers
-Fritz

@dvarrazzo
Copy link
Member

What version of Python and pip? What hardware platform is that Windows?

@felfert
Copy link
Author

felfert commented Oct 12, 2020

What version of Python and pip? What hardware platform is that Windows?

python 3.9.0 amd64
pip is always the latest, because before using pip, we always run python.exe -m pip install --upgrade pip

In the meantime, i figured, that if I use the direct url to the whl file then it installs fine. Without that, pip just picks up the source instead of the binary.

@dvarrazzo
Copy link
Member

python 3.9 is not supported yet on windows: see #1160

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants