我试图在Mac上安装django-heroku,但出现以下错误

时间:2020-09-23 11:32:46

标签: psycopg2 pg-config

错误: 找不到pg_config可执行文件。

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.

For further information please check the 'doc/src/install.rst' file (also at
<https://www.psycopg.org/docs/install.html>).

----------------------------------------

错误:命令错误,退出状态为1:python setup.py egg_info检查日志以获取完整的命令输出。

我是一个初学者,因此我在上述所有因素上的知识都非常松散。简化的分步说明将不胜感激。

1 个答案:

答案 0 :(得分:0)

您可以尝试pip install psycopg2-binary,然后再次安装django-heroku。

错误只是说您的计算机找不到psycopg2-binary软件包