我正在创建 dbt 项目,但是运行命令时dbt init <name_project>
它返回了找不到的错误profiles.yml
in the .dbt
文件夹。所以我尝试访问默认位置的文件夹,但它不在那里。在 python 虚拟环境中安装 dbt-snowflake 是否存在更改安装默认行为的问题?
- 创建虚拟环境:
python3 -m venv venv
- 激活 venv:
source venv/bin/activate
- 更新点:
pip install --upgrade pip wheel setuptools
- 安装 dbt-snowflake:
pip install dbt-snowflake
- 尝试创建一个项目:
bt init <name_project>
但我收到此错误消息:
Usage: dbt init [OPTIONS] [PROJECT_NAME]
Try 'dbt init -h' for help.
Error: Invalid value for '--profiles-dir': Path '/Users/brunofonseca/.dbt' does not exist.
我看到默认位置是~/.dbt
,所以我尝试访问该文件夹,但它不存在。我也尝试运行命令dbt debug --config-dir
查找文件夹在哪里,但返回:
04:40:15 Running with dbt=1.5.0
04:40:15 [OpenCommand]: Unable to parse dict {'open_cmd': 'open', 'profiles_dir': PosixPath('/Users/brunofonseca/.dbt')}
04:40:15 To view your profiles.yml file, run:
最后。我试图找到profiles.yml
在 - 的里面venv
文件夹,但没有找到。
OBS:操作系统为macos。
你只需要创建.dbt
预先在您的主目录中放置文件夹,然后运行dbt init <name_project>
这将自动创建一个profiles.yml
在你的.dbt
file.
本文内容由网友自发贡献,版权归原作者所有,本站不承担相应法律责任。如您发现有涉嫌抄袭侵权的内容,请联系:hwhale#tublm.com(使用前将#替换为@)