You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Integration tests run with the --with-docker flag should connect to a postgres instance and run the tests
Actual behaviour
Failure to connect to database as root role
E sqlalchemy.exc.OperationalError: (psycopg2.OperationalError) connection to server on socket "/var/run/postgresql/.s.PGSQL.5432" failed: FATAL: role "root" does not exist
E
E (Background on this error at: https://sqlalche.me/e/14/e3q8)
/usr/local/lib/python3.10/dist-packages/psycopg2/__init__.py:122: OperationalError
Note: Stale issues will be automatically closed after a period of six months with no activity.
To ensure critical issues are not closed, tag them with the Github pinned tag.
If you are a community member and not a maintainer please escalate this issue to maintainers via GIS StackExchange or Slack.
The text was updated successfully, but these errors were encountered:
Isn't the point of running check_code.sh with the --with-docker flag to bypass the local setup of postgres and instead use the provided container with a pre-configured option? So in this case, I don't believe that part of the set up doc is relevant. Happy to discuss further though.
Referring to your docs:
Alternatively one can use the opendatacube/datacube-tests docker image to run tests. This docker includes database server pre-configured for running integration tests. Add --with-docker command line option as a first argument to ./check-code.sh script.
Expected behaviour
Integration tests run with the --with-docker flag should connect to a postgres instance and run the tests
Actual behaviour
Failure to connect to database as root role
Steps to reproduce the behaviour
./check-code.sh --with-docker integration_tests
Environment information
python == 3.11.4 <- in venv, 3.10.12 <- global
pytest == 7.4.0
Open Data Cube core, version 1.8.16.dev4+g24b046e7
Ubuntu 22.04.3 LTS
Additional Information
A temporary fix is mounting the datacube_information.conf file and changing the db_user to postgres, i.e.
In check_code.sh:
and in .datacube_integration.conf
The text was updated successfully, but these errors were encountered: