gpt4 book ai didi

python - 如何安装 GNUHealth?

转载 作者:太空宇宙 更新时间:2023-11-03 20:31:38 28 4
gpt4 key购买 nike

我按照下面提到的安装步骤进行操作,但遇到了 python 问题。

https://en.wikibooks.org/wiki/GNU_Health/Installation#Installing_GNU_Health_on_GNU/Linux_and_FreeBSD

在执行数据库实例初始化的步骤中,执行以下命令后遇到以下错误。

python3 ./trytond-admin --all --database=health

遇到错误:

Traceback (most recent call last):
File "./trytond-admin", line 21, in <module>
admin.run(options)
File "/home/gnuhealth/gnuhealth/tryton/server/trytond-4.6.18/trytond/admin.py", line 24, in run
with Transaction().start(db_name, 0, _nocache=True):
File "/home/gnuhealth/gnuhealth/tryton/server/trytond-4.6.18/trytond/transaction.py", line 88, in start
database = Database(database_name).connect()
File "/home/gnuhealth/gnuhealth/tryton/server/trytond-4.6.18/trytond/backend/postgresql/database.py", line 97, in __new__
**cls._connection_params(name))
File "/home/gnuhealth/.local/lib/python3.6/site-packages/psycopg2/pool.py", line 161, in __init__
self, minconn, maxconn, *args, **kwargs)
File "/home/gnuhealth/.local/lib/python3.6/site-packages/psycopg2/pool.py", line 58, in __init__
self._connect()
File "/home/gnuhealth/.local/lib/python3.6/site-packages/psycopg2/pool.py", line 62, in _connect
conn = psycopg2.connect(*self._args, **self._kwargs)
File "/home/gnuhealth/.local/lib/python3.6/site-packages/psycopg2/__init__.py", line 126, in connect
conn = _connect(dsn, connection_factory=connection_factory, **kwasync)
psycopg2.OperationalError: fe_sendauth: no password supplied


谁能帮我解决这个错误或告诉我我错过了什么?
根据错误,我怀疑连接到数据库有困难,因为没有指定密码。

最佳答案

您似乎没有使用连接数据库的凭据配置 URI。您可以在http://docs.tryton.org/projects/server/en/latest/topics/configuration.html#uri找到配置文件的描述。一旦有了配置文件,您必须运行如下命令:

python3 ./trytond-admin --all --database=health -c/path/to/trytond.conf

关于python - 如何安装 GNUHealth?,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/57470881/

28 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com