El 17/10/17 a les 03:27, PMan ha escrit:
On Sunday, October 15, 2017 at 10:40:06 AM UTC-4, PMan wrote:
On Saturday, October 14, 2017 at 11:17:20 PM UTC-4, Mark Shane Hayden wrote:
On Oct 14, 2017 01:55, "PMan" <[email protected]> wrote:
Greetings!
I'm trying to install 4.4.4 from source on Cloud Linux 7 with cagefs.
My environment:
Postgres 9.6, which I know is working, because it is the backend for another
app on that server that has been running for months.
Virtual environment (VE): Python 3.6
I try to test install from the command line Inside active VE:
./bin/trytond -c /opt/Tryton/etc/trytond.conf
This gives me this error:
'trytond.backend', db_type)
ValueError: not enough values to unpack (expected 1, got 0)
This looks like an incorrectly specified database URI. The error message you
sent later seems to show it knows it's a postgresql type database but the
connection info was not supplied. See below...
Here are the relevant parts of trytond.conf:
[web]
# Settings for the web interface
# The IP/host and port number of the interface
# (Internal default: localhost:8000)
#
# Listen on all interfaces (IPv4)
listen = localhost:8000
#
# Listen on all interfaces (IPv4 and IPv6)
#listen = [::]:8000
# The hostname for this interface
#hostname =
# The root path to retrieve data for GET requests
root = /path/to/sao-4.4.4
[database]
# Database related settings
# The URI to connect to the SQL database (following RFC-3986)
# uri = database://username:password@host:port/
# (Internal default: sqlite:// (i.e. a local SQLite database))
#
# PostgreSQL via Unix domain sockets
# (e.g. PostgreSQL database running on the same machine (localhost))
#uri = postgresql://tryton:tryton@/
#
# PostgreSQL via TCP/IP
# (e.g. connecting to a PostgreSQL database running on a remote machine or
# by means of md5 authentication. Needs PostgreSQL to be configured to accept
# those connections (pg_hba.conf).)
uri = postgresql://username:passwordlocalhost:5432/
^^^HERE^^^
Is this exactly how it is in your config file? The @ sign as missing so the
parser can't unpack (separate) the credentials and the host:port
Should be username:password@localhost:5432
# The path to the directory where the Tryton Server stores files.
# The server must have write permissions to this directory.
# (Internal default: /var/lib/trytond)
path = /var/lib/trytond
# Shall available databases be listed in the client?
#list = True
# The number of retries of the Tryton Server when there are errors
# in a request to the database
#retry = 5
# The primary language, that is used to store entries in translatable
# fields into the database.
language = en_US
Is there a way to set db type in the config file?
Thanks in advance!
--
You received this message because you are subscribed to the Google Groups
"tryton" group.
To view this discussion on the web visit
https://groups.google.com/d/msgid/tryton/8c640812-3206-4681-a353-71eece762f64%40googlegroups.com.
My mistake! When I replaced the real credentials with the generic username:password I
left out the "@". In the config, it is db_name:username:password@localhost:5432
(I removed the trailing slash).
After removing the trailing slach, I still get the same error.
I have confirmed that in the directory:
/opt/Tryton/lib/python3.6/site-packages/trytond-4.4.4-py3.6.egg/trytond/modules
and directory:
/opt/Tryton/trytond-4.4.4/trytond/modules
there is no module “trytond.backend”.
The Tryton/lib… directory contains the file: __init__.py and the directory:
__pycache__ and nothing else. The Tryton/trytond-4.4.4… directory only contains
__init__.py.
I installed trytond by downloading the source from
http://www.tryton.org/download.html, checking the gpg signature, expanding the
tarball in a python 3.6 virtual environment (called Tryton), cd’ing into the
new directory, and doing: python setup.py install.
What am I missing?
The trytond/backend should contain a postgresql directory as the
postgresql backend is inlcuded by default.
Probably you have a typo on the database uri driver. If you are using
postgresql your uri should start with postgresql:
Hope it helps.
--
Sergi Almacellas Abellana
www.koolpi.com
Twitter: @pokoli_srk
--
You received this message because you are subscribed to the Google Groups
"tryton" group.
To view this discussion on the web visit
https://groups.google.com/d/msgid/tryton/b5a90b87-5390-9039-2a11-b600c5528c5a%40koolpi.com.