python - 在 Windows 10 上找不到 pg_config 可执行文件
问题描述
我已经安装了 PostgreSQL。我想我需要在 windows 上安装 libpq-dev 来解决这个问题,但是如何安装呢?
命令 python setup.py egg_info 的完整输出:运行 egg_info 创建 pip-egg-info\psycopg2_binary.egg-info 写入 pip-egg-info\psycopg2_binary.egg-info\PKG-INFO 写入 dependency_links 到 pip-egg-info\psycopg2_binary .egg-info\dependency_links.txt 将顶级名称写入 pip-egg-info\psycopg2_binary.egg-info\top_level.txt 写入清单文件 'pip-egg-info\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.
For further information please check the 'doc/src/install.rst' file (also at
<http://initd.org/psycopg/docs/install.html>).
解决方案
您可能已经安装了它,只是不在您的PATH
.
您可以SET
在命令行上使用来更改路径,这样pg_config
就可以了。
推荐阅读
- c# - 一对一关系实体框架出错
- oracle - 执行完成时,Oracle sql 不会从 temp 释放空间
- amazon-web-services - 无法将图像从 AWS ECR 拉到我在 AWS 上的 kubernetes 集群
- microsoft-graph-api - 无法使用 Microsoft Graph 资源管理器发送电子邮件
- java - 无法从 Maven 存储库中找到 play-services-maps.jar - 反应原生
- python - 更改部分变量的值 - Python
- html - 特定网页的 Firefox 字体呈现方式不同
- python - 删除 /。打印文件名时的空格
- c#-4.0 - '',十六进制值 0x1F,不是有效字符。第 1 行,第 1 项
- android - 从测试覆盖率中排除 Dagger 2 生成的类