Port 5432 failed: FATAL: password authentication failed for user "admin"

can seem to figure out why failing. I can still logon to tryton.

<frozen importlib._bootstrap>:283: DeprecationWarning: the load_module() method is deprecated and slated for removal in Python 3.12; use exec_module() instead
/home/awes7/projects/training5/.my_env5/lib/python3.10/site-packages/trytond/backend/postgresql/database.py:245: UserWarning: The path specified in the URI will be overridden
  warnings.warn("The path specified in the URI will be overridden")
connection to "training5" failed
Traceback (most recent call last):
  File "/home/awes7/projects/training5/.my_env5/lib/python3.10/site-packages/trytond/backend/postgresql/database.py", line 225, in __new__
    inst._connpool = ThreadedConnectionPool(
  File "/home/awes7/projects/training5/.my_env5/lib/python3.10/site-packages/psycopg2/pool.py", line 161, in __init__
    AbstractConnectionPool.__init__(
  File "/home/awes7/projects/training5/.my_env5/lib/python3.10/site-packages/psycopg2/pool.py", line 59, in __init__
    self._connect()
  File "/home/awes7/projects/training5/.my_env5/lib/python3.10/site-packages/psycopg2/pool.py", line 63, in _connect
    conn = psycopg2.connect(*self._args, **self._kwargs)
  File "/home/awes7/projects/training5/.my_env5/lib/python3.10/site-packages/psycopg2/__init__.py", line 122, in connect
    conn = _connect(dsn, connection_factory=connection_factory, **kwasync)
psycopg2.OperationalError: connection to server at "localhost" (127.0.0.1), port 5432 failed: FATAL:  password authentication failed for user "admin"
connection to server at "localhost" (127.0.0.1), port 5432 failed: FATAL:  password authentication failed for user "admin"

Traceback (most recent call last):
  File "/home/awes7/projects/training5/account_us/party_import2.py", line 10, in <module>
    config.set_trytond(f'postgresql://{DB_USER}:{DB_PASSWORD}@localhost/{DB_NAME}')  # Set the Trytond connection parameters
  File "/home/awes7/projects/training5/.my_env5/lib/python3.10/site-packages/proteus/config.py", line 313, in set_trytond
    _CONFIG.current = TrytondConfig(database, user, config_file=config_file)
  File "/home/awes7/projects/training5/.my_env5/lib/python3.10/site-packages/proteus/config.py", line 266, in __init__
    self.pool.init()
  File "/home/awes7/projects/training5/.my_env5/lib/python3.10/site-packages/trytond/pool.py", line 165, in init
    restart = not load_modules(
  File "/home/awes7/projects/training5/.my_env5/lib/python3.10/site-packages/trytond/modules/__init__.py", line 439, in load_modules
    with Transaction().start(database_name, 0):
  File "/home/awes7/projects/training5/.my_env5/lib/python3.10/site-packages/trytond/transaction.py", line 127, in start
    database = backend.Database(database_name).connect()
  File "/home/awes7/projects/training5/.my_env5/lib/python3.10/site-packages/trytond/backend/postgresql/database.py", line 225, in __new__
    inst._connpool = ThreadedConnectionPool(
  File "/home/awes7/projects/training5/.my_env5/lib/python3.10/site-packages/psycopg2/pool.py", line 161, in __init__
    AbstractConnectionPool.__init__(
  File "/home/awes7/projects/training5/.my_env5/lib/python3.10/site-packages/psycopg2/pool.py", line 59, in __init__
    self._connect()
  File "/home/awes7/projects/training5/.my_env5/lib/python3.10/site-packages/psycopg2/pool.py", line 63, in _connect
    conn = psycopg2.connect(*self._args, **self._kwargs)
  File "/home/awes7/projects/training5/.my_env5/lib/python3.10/site-packages/psycopg2/__init__.py", line 122, in connect
    conn = _connect(dsn, connection_factory=connection_factory, **kwasync)
psycopg2.OperationalError: connection to server at "localhost" (127.0.0.1), port 5432 failed: FATAL:  password authentication failed for user "admin"
connection to server at "localhost" (127.0.0.1), port 5432 failed: FATAL:  password authentication failed for user "admin"

Trytond can not authenticate to the database.
The users for tryton and database are separate.

You need to set the postgresql password in trytond.conf or environment variable.
I think it is unlikely that the databsse user is admin.

You can check your postgresql database with psql