安装PIP安装DBT-Postgres
我想刚刚安装了 dbt-postgres 根据文章 https: //docs.getdbt.com/dbt-cli/install/pip 使用命令 pip安装dbt-postgres 安装后,我到处都已经满足要求
当我尝试命令查看版本时,我有错误 'dbt'不被认为是内部或外部命令, 可操作的程序或批处理文件。 这是否意味着我没有下载? 如何检查版本?
I guess just installed dbt-postgres according to the article https://docs.getdbt.com/dbt-cli/install/pip
using command pip install dbt-postgres
after the installation I have everywhere Requirements already satisfied
When I try the command to see the version I have an error
''dbt' is not recognized as an internal or external command,
operable program or batch file.'
Does this mean that I didn't downloaded this?
How to check the version?
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(1)
pip
说您已经在本地Python 3.10环境中安装了DBT-POSTGRES
已安装(“需求已经满足”)。Windows抱怨是因为Python的站点包装目录不在您的路上。这是典型的;根据您在Windows上安装Python的方式,它不会自动添加到您的路径中。 (路径是一个环境变量,告诉您的外壳在哪里搜索您输入的命令 - 每个命令是某个地方文件夹中可执行文件的名称,而路径是一个可以搜索这些可执行文件的文件夹列表) 。
有几种方法可以将Python添加到您的路径中 - 请参阅官方文档关于这个主题。如果您不熟悉所有这些,那么最好的选择可能是卸载和重新安装Python。 现在最好的方法。
但是,这里还有另一个问题 - 您正在尝试在Python 3.10上运行DBT,但目前DBT仅支持Python的较旧版本(3.7-3.9)。因此,当您重新安装Python时,您将要指定3.9(我链接到上面)。
在机器上管理多个版本的Python可能是一种真正的痛苦,尤其是在Windows上。如果您在组织中拥有更有经验的人(例如一个非常了解Python的工程师),那么在您工作时,值得您让某人与您配对的时间。
pip
is saying that you already havedbt-postgres
installed ("Requirement already satisfied") in your local Python 3.10 environment.Windows is complaining because that Python's site-packages directory is not on your PATH. This is typical; depending on how you install Python on Windows, it is not automatically added to your PATH. (PATH is an environment variable that tells your shell where to search for the commands you type in -- each command is the name of an executable file in a folder somewhere, and PATH is a list of folders to search in for those executable files).
There are a few ways to add Python to your PATH -- see the official docs on this subject. If you're new to all of this, your best bet might be to uninstall and re-install Python. The Windows Store is now the best way to do this.
HOWEVER there is another issue here too -- you're trying to run dbt on Python 3.10, but currently dbt only supports older versions of Python (3.7-3.9). So when you re-install Python, you're going to want to specify 3.9 (which I linked to above).
Managing multiple versions of Python on your machine can be a real pain, especially on Windows. If you have someone more experienced in your organization (like an engineer who knows Python well), it's well worth your time to get someone to pair with you on this while you work it out.