PavelPancocha/unfoldDemo

Demo not running

Closed this issue · 7 comments

I see these errors:

unfoldDemo on  master on 🐳 v20.10.23
➜ docker-compose build
[+] Building 200.8s (14/14) FINISHED
 => [internal] load build definition from Dockerfile                                    0.0s
 => => transferring dockerfile: 837B                                                    0.0s
 => [internal] load .dockerignore                                                       0.0s
 => => transferring context: 2B                                                         0.0s
 => [internal] load metadata for docker.io/library/python:3.11-bullseye                 2.5s
 => [auth] library/python:pull token for registry-1.docker.io                           0.0s
 => [1/8] FROM docker.io/library/python:3.11-bullseye@sha256:21ce92a075cf9c454a936f9  156.1s
 => => resolve docker.io/library/python:3.11-bullseye@sha256:21ce92a075cf9c454a936f925  0.0s
 => => sha256:21ce92a075cf9c454a936f925e058b4d8fc0cfc7a05b9e877bed4687 1.65kB / 1.65kB  0.0s
 => => sha256:74707af2d4ec537fd45394f8f6a9d93b1cd6b939f2dc942c2c09cdfa 7.92kB / 7.92kB  0.0s
 => => sha256:8022b074731d9ecee7f4fba79b993920973811dda168bbc08636f 53.70MB / 53.70MB  58.1s
 => => sha256:7971239fe1d69763272ccc0b2527efa95547d37c53630ed0a71db4e0 5.15MB / 5.15MB  6.0s
 => => sha256:26c861b53509d61c37240d2f80efb3a351d2f1d7f4f8e8ec2e500 10.87MB / 10.87MB  20.0s
 => => sha256:9c5aa3f126bd652d22fcb5fbaea0446609747aa71454fd01a07810b6 2.22kB / 2.22kB  0.0s
 => => sha256:1714880ecc1c021a5f708f4369f91d3c2c53b998a56d563d0a9aa 54.68MB / 54.68MB  84.0s
 => => sha256:895a945a1f9ba441c2748501c4d46569edfbc2bfbdb9b47d41 189.73MB / 189.73MB  153.2s
 => => sha256:2a83fe9e3053a5f52e699f1078c2abeaad849bb81da9068f1aa541b 6.40MB / 6.40MB  67.0s
 => => extracting sha256:8022b074731d9ecee7f4fba79b993920973811dda168bbc08636f18523b90  0.7s
 => => extracting sha256:7971239fe1d69763272ccc0b2527efa95547d37c53630ed0a71db4e00d3ef  0.1s
 => => extracting sha256:26c861b53509d61c37240d2f80efb3a351d2f1d7f4f8e8ec2e5004c1d86af  0.1s
 => => sha256:cad84c97de70ce8ac18eaca0f13ed88dd622a1ee17d4f47c88941 19.93MB / 19.93MB  92.3s
 => => sha256:317609cadfd3e8a9eb5393f8aae884de904c93391615b2eb841f1744970 243B / 243B  84.6s
 => => extracting sha256:1714880ecc1c021a5f708f4369f91d3c2c53b998a56d563d0a9aa9be2488d  0.8s
 => => sha256:f756083c502e7d8ae0753f9c828624027c0b16b8d4a203c46929e96 3.08MB / 3.08MB  89.7s
 => => extracting sha256:895a945a1f9ba441c2748501c4d46569edfbc2bfbdb9b47d41e753e752247  2.2s
 => => extracting sha256:2a83fe9e3053a5f52e699f1078c2abeaad849bb81da9068f1aa541bb5673a  0.1s
 => => extracting sha256:cad84c97de70ce8ac18eaca0f13ed88dd622a1ee17d4f47c88941116b83a8  0.2s
 => => extracting sha256:317609cadfd3e8a9eb5393f8aae884de904c93391615b2eb841f17449709e  0.0s
 => => extracting sha256:f756083c502e7d8ae0753f9c828624027c0b16b8d4a203c46929e9606b459  0.1s
 => [internal] load build context                                                       0.0s
 => => transferring context: 56.20kB                                                    0.0s
 => [2/8] RUN apt-get update &&     apt-get install -y binutils libproj-dev gdal-bin   28.9s
 => [3/8] WORKDIR /app                                                                  0.0s
 => [4/8] COPY requirements.txt .                                                       0.0s
 => [5/8] RUN pip install --no-cache-dir -r requirements.txt                           12.4s
 => [6/8] COPY . .                                                                      0.0s
 => [7/8] COPY wait-for-postgres.sh /app                                                0.0s
 => [8/8] RUN chmod +x wait-for-postgres.sh                                             0.2s
 => exporting to image                                                                  0.5s
 => => exporting layers                                                                 0.5s
 => => writing image sha256:9635bbb47539fa1dd3b6e0ea4cf5afd9ee14cdcb9605576d32b19bef17  0.0s
 => => naming to docker.io/library/unfolddemo-app                                       0.0s

unfoldDemo on  master on 🐳 v20.10.23 took 3m 22s
➜ docker-compose up
[+] Running 17/17
 ⠿ db Pulled                                                                          101.5s
   ⠿ 7a6db449b51b Pull complete                                                        37.7s
   ⠿ b4f184bc0704 Pull complete                                                        37.8s
   ⠿ 606a73c0d34a Pull complete                                                        37.8s
   ⠿ c39f1600d2b6 Pull complete                                                        37.9s
   ⠿ 31f42f92b0fe Pull complete                                                        38.1s
   ⠿ c8b67d2b0354 Pull complete                                                        38.1s
   ⠿ 31107b8480ee Pull complete                                                        38.2s
   ⠿ b26434cf8bfa Pull complete                                                        38.2s
   ⠿ 36220bd76bfa Pull complete                                                        97.8s
   ⠿ b79e75c4a0c2 Pull complete                                                        97.8s
   ⠿ cc1ab699dda5 Pull complete                                                        97.9s
   ⠿ 37312064dd9b Pull complete                                                        97.9s
   ⠿ 4bce56fcbfe5 Pull complete                                                        98.0s
   ⠿ e511dca02d1b Pull complete                                                        98.8s
   ⠿ 2f1037ffdf48 Pull complete                                                        98.9s
   ⠿ 9f7f04fcc25c Pull complete                                                        98.9s
[+] Running 4/3
 ⠿ Network unfolddemo_default                                                                                                                        Created 0.0s                    0.0s
 ⠿ Volume "unfolddemo_postgres_data_unfold"                                                                                                          Created 0.0s
 ⠿ Container unfolddemo-db-1                                                                                                                         Created 0.4s
 ⠋ db The requested image's platform (linux/amd64) does not match the detected host platform (linux/arm64/v8) and no specific platform was requested  0.0s
 ⠿ Container unfolddemo-app-1                                                                                                                        Created 0.1s
Attaching to unfolddemo-app-1, unfolddemo-db-1
unfolddemo-app-1  | Traceback (most recent call last):
unfolddemo-app-1  |   File "/usr/local/lib/python3.11/site-packages/django/db/backends/base/base.py", line 282, in ensure_connection
unfolddemo-app-1  |     self.connect()
unfolddemo-app-1  |   File "/usr/local/lib/python3.11/site-packages/django/utils/asyncio.py", line 26, in inner
unfolddemo-app-1  |     return func(*args, **kwargs)
unfolddemo-app-1  |            ^^^^^^^^^^^^^^^^^^^^^
unfolddemo-app-1  |   File "/usr/local/lib/python3.11/site-packages/django/db/backends/base/base.py", line 263, in connect
unfolddemo-app-1  |     self.connection = self.get_new_connection(conn_params)
unfolddemo-app-1  |                       ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
unfolddemo-app-1  |   File "/usr/local/lib/python3.11/site-packages/django/utils/asyncio.py", line 26, in inner
unfolddemo-app-1  |     return func(*args, **kwargs)
unfolddemo-app-1  |            ^^^^^^^^^^^^^^^^^^^^^
unfolddemo-app-1  |   File "/usr/local/lib/python3.11/site-packages/django/db/backends/postgresql/base.py", line 215, in get_new_connection
unfolddemo-app-1  |     connection = Database.connect(**conn_params)
unfolddemo-app-1  |                  ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
unfolddemo-app-1  |   File "/usr/local/lib/python3.11/site-packages/psycopg2/__init__.py", line 122, in connect
unfolddemo-app-1  |     conn = _connect(dsn, connection_factory=connection_factory, **kwasync)
unfolddemo-app-1  |            ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
unfolddemo-app-1  | psycopg2.OperationalError: could not connect to server: Connection refused
unfolddemo-app-1  | 	Is the server running on host "db" (172.18.0.2) and accepting
unfolddemo-app-1  | 	TCP/IP connections on port 5432?
unfolddemo-app-1  |
unfolddemo-app-1  |
unfolddemo-app-1  | The above exception was the direct cause of the following exception:
unfolddemo-app-1  |
unfolddemo-app-1  | Traceback (most recent call last):
unfolddemo-app-1  |   File "/app/manage.py", line 22, in <module>
unfolddemo-app-1  |     main()
unfolddemo-app-1  |   File "/app/manage.py", line 18, in main
unfolddemo-app-1  |     execute_from_command_line(sys.argv)
unfolddemo-app-1  |   File "/usr/local/lib/python3.11/site-packages/django/core/management/__init__.py", line 446, in execute_from_command_line
unfolddemo-app-1  |     utility.execute()
unfolddemo-app-1  |   File "/usr/local/lib/python3.11/site-packages/django/core/management/__init__.py", line 440, in execute
unfolddemo-app-1  |     self.fetch_command(subcommand).run_from_argv(self.argv)
unfolddemo-app-1  |   File "/usr/local/lib/python3.11/site-packages/django/core/management/base.py", line 402, in run_from_argv
unfolddemo-app-1  |     self.execute(*args, **cmd_options)
unfolddemo-app-1  |   File "/usr/local/lib/python3.11/site-packages/django/core/management/base.py", line 448, in execute
unfolddemo-app-1  |     output = self.handle(*args, **options)
unfolddemo-app-1  |              ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
unfolddemo-app-1  |   File "/usr/local/lib/python3.11/site-packages/django/core/management/base.py", line 96, in wrapped
unfolddemo-app-1  |     res = handle_func(*args, **kwargs)
unfolddemo-app-1  |           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^
unfolddemo-app-1  |   File "/usr/local/lib/python3.11/site-packages/django/core/management/commands/migrate.py", line 112, in handle
unfolddemo-app-1  |     connection.prepare_database()
unfolddemo-app-1  |   File "/usr/local/lib/python3.11/site-packages/django/contrib/gis/db/backends/postgis/base.py", line 25, in prepare_database
unfolddemo-app-1  |     with self.cursor() as cursor:
unfolddemo-app-1  |          ^^^^^^^^^^^^^
unfolddemo-app-1  |   File "/usr/local/lib/python3.11/site-packages/django/utils/asyncio.py", line 26, in inner
unfolddemo-app-1  |     return func(*args, **kwargs)
unfolddemo-app-1  |            ^^^^^^^^^^^^^^^^^^^^^
unfolddemo-app-1  |   File "/usr/local/lib/python3.11/site-packages/django/db/backends/base/base.py", line 323, in cursor
unfolddemo-app-1  |     return self._cursor()
unfolddemo-app-1  |            ^^^^^^^^^^^^^^
unfolddemo-app-1  |   File "/usr/local/lib/python3.11/site-packages/django/db/backends/base/base.py", line 299, in _cursor
unfolddemo-app-1  |     self.ensure_connection()
unfolddemo-app-1  |   File "/usr/local/lib/python3.11/site-packages/django/utils/asyncio.py", line 26, in inner
unfolddemo-app-1  |     return func(*args, **kwargs)
unfolddemo-app-1  |            ^^^^^^^^^^^^^^^^^^^^^
unfolddemo-app-1  |   File "/usr/local/lib/python3.11/site-packages/django/db/backends/base/base.py", line 281, in ensure_connection
unfolddemo-app-1  |     with self.wrap_database_errors:
unfolddemo-app-1  |   File "/usr/local/lib/python3.11/site-packages/django/db/utils.py", line 91, in __exit__
unfolddemo-app-1  |     raise dj_exc_value.with_traceback(traceback) from exc_value
unfolddemo-app-1  |   File "/usr/local/lib/python3.11/site-packages/django/db/backends/base/base.py", line 282, in ensure_connection
unfolddemo-app-1  |     self.connect()
unfolddemo-app-1  |   File "/usr/local/lib/python3.11/site-packages/django/utils/asyncio.py", line 26, in inner
unfolddemo-app-1  |     return func(*args, **kwargs)
unfolddemo-app-1  |            ^^^^^^^^^^^^^^^^^^^^^
unfolddemo-app-1  |   File "/usr/local/lib/python3.11/site-packages/django/db/backends/base/base.py", line 263, in connect
unfolddemo-app-1  |     self.connection = self.get_new_connection(conn_params)
unfolddemo-app-1  |                       ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
unfolddemo-app-1  |   File "/usr/local/lib/python3.11/site-packages/django/utils/asyncio.py", line 26, in inner
unfolddemo-app-1  |     return func(*args, **kwargs)
unfolddemo-app-1  |            ^^^^^^^^^^^^^^^^^^^^^
unfolddemo-app-1  |   File "/usr/local/lib/python3.11/site-packages/django/db/backends/postgresql/base.py", line 215, in get_new_connection
unfolddemo-app-1  |     connection = Database.connect(**conn_params)
unfolddemo-app-1  |                  ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
unfolddemo-app-1  |   File "/usr/local/lib/python3.11/site-packages/psycopg2/__init__.py", line 122, in connect
unfolddemo-app-1  |     conn = _connect(dsn, connection_factory=connection_factory, **kwasync)
unfolddemo-app-1  |            ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
unfolddemo-app-1  | django.db.utils.OperationalError: could not connect to server: Connection refused
unfolddemo-app-1  | 	Is the server running on host "db" (172.18.0.2) and accepting
unfolddemo-app-1  | 	TCP/IP connections on port 5432?
unfolddemo-app-1  |
unfolddemo-db-1   | The files belonging to this database system will be owned by user "postgres".
unfolddemo-db-1   | This user must also own the server process.
unfolddemo-db-1   |
unfolddemo-db-1   | The database cluster will be initialized with locale "en_US.utf8".
unfolddemo-db-1   | The default database encoding has accordingly been set to "UTF8".
unfolddemo-db-1   | The default text search configuration will be set to "english".
unfolddemo-db-1   |
unfolddemo-db-1   | Data page checksums are disabled.
unfolddemo-db-1   |
unfolddemo-db-1   | fixing permissions on existing directory /var/lib/postgresql/data ... ok
unfolddemo-db-1   | creating subdirectories ... ok
unfolddemo-db-1   | selecting dynamic shared memory implementation ... posix
unfolddemo-db-1   | selecting default max_connections ... 100
unfolddemo-db-1   | selecting default shared_buffers ... 128MB
unfolddemo-db-1   | selecting default time zone ... Etc/UTC
unfolddemo-db-1   | creating configuration files ... ok
unfolddemo-app-1 exited with code 1
unfolddemo-db-1   | running bootstrap script ... ok
unfolddemo-db-1   | performing post-bootstrap initialization ... ok
unfolddemo-db-1   | syncing data to disk ... ok
unfolddemo-db-1   |
unfolddemo-db-1   | initdb: warning: enabling "trust" authentication for local connections
unfolddemo-db-1   | You can change this by editing pg_hba.conf or using the option -A, or
unfolddemo-db-1   | --auth-local and --auth-host, the next time you run initdb.
unfolddemo-db-1   |
unfolddemo-db-1   | Success. You can now start the database server using:
unfolddemo-db-1   |
unfolddemo-db-1   |     pg_ctl -D /var/lib/postgresql/data -l logfile start
unfolddemo-db-1   |
unfolddemo-db-1   | waiting for server to start....2023-03-31 18:27:41.754 UTC [124] LOG:  starting PostgreSQL 14.5 (Debian 14.5-1.pgdg110+1) on x86_64-pc-linux-gnu, compiled by gcc (Debian 10.2.1-6) 10.2.1 20210110, 64-bit
unfolddemo-db-1   | 2023-03-31 18:27:41.777 UTC [124] LOG:  listening on Unix socket "/var/run/postgresql/.s.PGSQL.5432"
unfolddemo-db-1   | 2023-03-31 18:27:41.830 UTC [128] LOG:  database system was shut down at 2023-03-31 18:27:41 UTC
unfolddemo-db-1   | 2023-03-31 18:27:41.917 UTC [124] LOG:  database system is ready to accept connections
unfolddemo-db-1   |  done
unfolddemo-db-1   | server started
unfolddemo-db-1   | CREATE DATABASE
unfolddemo-db-1   |
unfolddemo-db-1   |
unfolddemo-db-1   | /usr/local/bin/docker-entrypoint.sh: sourcing /docker-entrypoint-initdb.d/10_postgis.sh
unfolddemo-db-1   | CREATE DATABASE
unfolddemo-db-1   | Loading PostGIS extensions into template_postgis
unfolddemo-db-1   | CREATE EXTENSION
unfolddemo-db-1   | CREATE EXTENSION
unfolddemo-db-1   | You are now connected to database "template_postgis" as user "postgres".
unfolddemo-db-1   | CREATE EXTENSION
unfolddemo-db-1   | CREATE EXTENSION
unfolddemo-db-1   | Loading PostGIS extensions into unfold
unfolddemo-db-1   | CREATE EXTENSION
unfolddemo-db-1   | CREATE EXTENSION
unfolddemo-db-1   | You are now connected to database "unfold" as user "postgres".
unfolddemo-db-1   | CREATE EXTENSION
unfolddemo-db-1   | CREATE EXTENSION
unfolddemo-db-1   |
unfolddemo-db-1   | 2023-03-31 18:27:54.700 UTC [124] LOG:  received fast shutdown request
unfolddemo-db-1   | 2023-03-31 18:27:54.701 UTC [124] LOG:  aborting any active transactions
unfolddemo-db-1   | waiting for server to shut down....2023-03-31 18:27:54.711 UTC [124] LOG:  background worker "logical replication launcher" (PID 140) exited with exit code 1
unfolddemo-db-1   | 2023-03-31 18:27:54.714 UTC [130] LOG:  shutting down
unfolddemo-db-1   | 2023-03-31 18:27:54.865 UTC [124] LOG:  database system is shut down
unfolddemo-db-1   |  done
unfolddemo-db-1   | server stopped
unfolddemo-db-1   |
unfolddemo-db-1   | PostgreSQL init process complete; ready for start up.
unfolddemo-db-1   |
unfolddemo-db-1   | 2023-03-31 18:27:55.012 UTC [1] LOG:  starting PostgreSQL 14.5 (Debian 14.5-1.pgdg110+1) on x86_64-pc-linux-gnu, compiled by gcc (Debian 10.2.1-6) 10.2.1 20210110, 64-bit
unfolddemo-db-1   | 2023-03-31 18:27:55.016 UTC [1] LOG:  listening on IPv4 address "0.0.0.0", port 5432
unfolddemo-db-1   | 2023-03-31 18:27:55.016 UTC [1] LOG:  listening on IPv6 address "::", port 5432
unfolddemo-db-1   | 2023-03-31 18:27:55.019 UTC [1] LOG:  listening on Unix socket "/var/run/postgresql/.s.PGSQL.5432"
unfolddemo-db-1   | 2023-03-31 18:27:55.041 UTC [184] LOG:  database system was shut down at 2023-03-31 18:27:54 UTC
unfolddemo-db-1   | 2023-03-31 18:27:55.057 UTC [1] LOG:  database system is ready to accept connections

@googol7 Thanks - The problem occurs only when you run it for fist time, as Database than takes more time to setup. But try it now please, I fixed it :)

@PavelPancocha I'm getting this error with the recent version:

➜ docker-compose up --build
[+] Building 1.8s (12/12) FINISHED
 => [internal] load build definition from Dockerfile                                                                                 0.0s
 => => transferring dockerfile: 32B                                                                                                  0.0s
 => [internal] load .dockerignore                                                                                                    0.0s
 => => transferring context: 2B                                                                                                      0.0s
 => [internal] load metadata for docker.io/library/python:3.11-bullseye                                                              1.7s
 => [auth] library/python:pull token for registry-1.docker.io                                                                        0.0s
 => [internal] load build context                                                                                                    0.0s
 => => transferring context: 6.84kB                                                                                                  0.0s
 => [1/6] FROM docker.io/library/python:3.11-bullseye@sha256:21ce92a075cf9c454a936f925e058b4d8fc0cfc7a05b9e877bed4687c51a5658        0.0s
 => CACHED [2/6] RUN apt-get update &&     apt-get install -y binutils libproj-dev gdal-bin postgresql-client                        0.0s
 => CACHED [3/6] WORKDIR /app                                                                                                        0.0s
 => CACHED [4/6] COPY requirements.txt .                                                                                             0.0s
 => CACHED [5/6] RUN pip install --no-cache-dir -r requirements.txt                                                                  0.0s
 => [6/6] COPY . .                                                                                                                   0.0s
 => exporting to image                                                                                                               0.0s
 => => exporting layers                                                                                                              0.0s
 => => writing image sha256:8ca8d224ec2f87ee3265bafc83fb2071ec2ef21a1bd36d8de5bc82a39e47c0db                                         0.0s
 => => naming to docker.io/library/unfolddemo-app                                                                                    0.0s
[+] Running 2/2
 ⠿ Container unfolddemo-db-1   Created                                                                                               0.0s
 ⠿ Container unfolddemo-app-1  Recreated                                                                                             0.1s
Attaching to unfolddemo-app-1, unfolddemo-db-1
unfolddemo-app-1  | db:5432 - no response
unfolddemo-app-1  | Waiting for database...
unfolddemo-db-1   |
unfolddemo-db-1   | PostgreSQL Database directory appears to contain a database; Skipping initialization
unfolddemo-db-1   |
unfolddemo-db-1   | 2023-04-03 10:49:40.978 UTC [1] LOG:  starting PostgreSQL 14.5 (Debian 14.5-1.pgdg110+1) on x86_64-pc-linux-gnu, compiled by gcc (Debian 10.2.1-6) 10.2.1 20210110, 64-bit
unfolddemo-db-1   | 2023-04-03 10:49:40.981 UTC [1] LOG:  listening on IPv4 address "0.0.0.0", port 5432
unfolddemo-db-1   | 2023-04-03 10:49:40.981 UTC [1] LOG:  listening on IPv6 address "::", port 5432
unfolddemo-db-1   | 2023-04-03 10:49:40.983 UTC [1] LOG:  listening on Unix socket "/var/run/postgresql/.s.PGSQL.5432"
unfolddemo-db-1   | 2023-04-03 10:49:41.004 UTC [62] LOG:  database system was shut down at 2023-04-03 10:49:03 UTC
unfolddemo-db-1   | 2023-04-03 10:49:41.022 UTC [1] LOG:  database system is ready to accept connections
unfolddemo-app-1  | db:5432 - accepting connections
unfolddemo-app-1  | System check identified some issues:
unfolddemo-app-1  |
unfolddemo-app-1  | WARNINGS:
unfolddemo-app-1  | ?: (debug_toolbar.W001) debug_toolbar.middleware.DebugToolbarMiddleware is missing from MIDDLEWARE.
unfolddemo-app-1  | 	HINT: Add debug_toolbar.middleware.DebugToolbarMiddleware to MIDDLEWARE.
unfolddemo-app-1  | Traceback (most recent call last):
unfolddemo-app-1  |   File "/usr/local/lib/python3.11/site-packages/django/db/backends/base/base.py", line 282, in ensure_connection
unfolddemo-app-1  | /app/unfoldDemo
unfolddemo-app-1  |     self.connect()
unfolddemo-app-1  |   File "/usr/local/lib/python3.11/site-packages/django/utils/asyncio.py", line 26, in inner
unfolddemo-app-1  |     return func(*args, **kwargs)
unfolddemo-app-1  |            ^^^^^^^^^^^^^^^^^^^^^
unfolddemo-app-1  |   File "/usr/local/lib/python3.11/site-packages/django/db/backends/base/base.py", line 263, in connect
unfolddemo-app-1  |     self.connection = self.get_new_connection(conn_params)
unfolddemo-app-1  |                       ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
unfolddemo-app-1  |   File "/usr/local/lib/python3.11/site-packages/django/utils/asyncio.py", line 26, in inner
unfolddemo-app-1  |     return func(*args, **kwargs)
unfolddemo-app-1  |            ^^^^^^^^^^^^^^^^^^^^^
unfolddemo-app-1  |   File "/usr/local/lib/python3.11/site-packages/django/db/backends/postgresql/base.py", line 215, in get_new_connection
unfolddemo-app-1  |     connection = Database.connect(**conn_params)
unfolddemo-app-1  |                  ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
unfolddemo-app-1  |   File "/usr/local/lib/python3.11/site-packages/psycopg2/__init__.py", line 122, in connect
unfolddemo-app-1  |     conn = _connect(dsn, connection_factory=connection_factory, **kwasync)
unfolddemo-app-1  |            ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
unfolddemo-app-1  | psycopg2.OperationalError: SCRAM authentication requires libpq version 10 or above
unfolddemo-app-1  |
unfolddemo-app-1  |
unfolddemo-app-1  | The above exception was the direct cause of the following exception:
unfolddemo-app-1  |
unfolddemo-app-1  | Traceback (most recent call last):
unfolddemo-app-1  |   File "/app/manage.py", line 22, in <module>
unfolddemo-app-1  |     main()
unfolddemo-app-1  |   File "/app/manage.py", line 18, in main
unfolddemo-app-1  |     execute_from_command_line(sys.argv)
unfolddemo-app-1  |   File "/usr/local/lib/python3.11/site-packages/django/core/management/__init__.py", line 446, in execute_from_command_line
unfolddemo-app-1  |     utility.execute()
unfolddemo-app-1  |   File "/usr/local/lib/python3.11/site-packages/django/core/management/__init__.py", line 440, in execute
unfolddemo-app-1  |     self.fetch_command(subcommand).run_from_argv(self.argv)
unfolddemo-app-1  |   File "/usr/local/lib/python3.11/site-packages/django/core/management/base.py", line 402, in run_from_argv
unfolddemo-app-1  |     self.execute(*args, **cmd_options)
unfolddemo-app-1  |   File "/usr/local/lib/python3.11/site-packages/django/core/management/base.py", line 448, in execute
unfolddemo-app-1  |     output = self.handle(*args, **options)
unfolddemo-app-1  |              ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
unfolddemo-app-1  |   File "/usr/local/lib/python3.11/site-packages/django/core/management/base.py", line 96, in wrapped
unfolddemo-app-1  |     res = handle_func(*args, **kwargs)
unfolddemo-app-1  |           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^
unfolddemo-app-1  |   File "/usr/local/lib/python3.11/site-packages/django/core/management/commands/migrate.py", line 112, in handle
unfolddemo-app-1  |     connection.prepare_database()
unfolddemo-app-1  |   File "/usr/local/lib/python3.11/site-packages/django/contrib/gis/db/backends/postgis/base.py", line 25, in prepare_database
unfolddemo-app-1  |     with self.cursor() as cursor:
unfolddemo-app-1  |          ^^^^^^^^^^^^^
unfolddemo-app-1  |   File "/usr/local/lib/python3.11/site-packages/django/utils/asyncio.py", line 26, in inner
unfolddemo-app-1  |     return func(*args, **kwargs)
unfolddemo-app-1  |            ^^^^^^^^^^^^^^^^^^^^^
unfolddemo-app-1  |   File "/usr/local/lib/python3.11/site-packages/django/db/backends/base/base.py", line 323, in cursor
unfolddemo-app-1  |     return self._cursor()
unfolddemo-app-1  |            ^^^^^^^^^^^^^^
unfolddemo-app-1  |   File "/usr/local/lib/python3.11/site-packages/django/db/backends/base/base.py", line 299, in _cursor
unfolddemo-app-1  |     self.ensure_connection()
unfolddemo-app-1  |   File "/usr/local/lib/python3.11/site-packages/django/utils/asyncio.py", line 26, in inner
unfolddemo-app-1  |     return func(*args, **kwargs)
unfolddemo-app-1  |            ^^^^^^^^^^^^^^^^^^^^^
unfolddemo-app-1  |   File "/usr/local/lib/python3.11/site-packages/django/db/backends/base/base.py", line 281, in ensure_connection
unfolddemo-app-1  |     with self.wrap_database_errors:
unfolddemo-app-1  |   File "/usr/local/lib/python3.11/site-packages/django/db/utils.py", line 91, in __exit__
unfolddemo-app-1  |     raise dj_exc_value.with_traceback(traceback) from exc_value
unfolddemo-app-1  |   File "/usr/local/lib/python3.11/site-packages/django/db/backends/base/base.py", line 282, in ensure_connection
unfolddemo-app-1  |     self.connect()
unfolddemo-app-1  |   File "/usr/local/lib/python3.11/site-packages/django/utils/asyncio.py", line 26, in inner
unfolddemo-app-1  |     return func(*args, **kwargs)
unfolddemo-app-1  |            ^^^^^^^^^^^^^^^^^^^^^
unfolddemo-app-1  |   File "/usr/local/lib/python3.11/site-packages/django/db/backends/base/base.py", line 263, in connect
unfolddemo-app-1  |     self.connection = self.get_new_connection(conn_params)
unfolddemo-app-1  |                       ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
unfolddemo-app-1  |   File "/usr/local/lib/python3.11/site-packages/django/utils/asyncio.py", line 26, in inner
unfolddemo-app-1  |     return func(*args, **kwargs)
unfolddemo-app-1  |            ^^^^^^^^^^^^^^^^^^^^^
unfolddemo-app-1  |   File "/usr/local/lib/python3.11/site-packages/django/db/backends/postgresql/base.py", line 215, in get_new_connection
unfolddemo-app-1  |     connection = Database.connect(**conn_params)
unfolddemo-app-1  |                  ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
unfolddemo-app-1  |   File "/usr/local/lib/python3.11/site-packages/psycopg2/__init__.py", line 122, in connect
unfolddemo-app-1  |     conn = _connect(dsn, connection_factory=connection_factory, **kwasync)
unfolddemo-app-1  |            ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
unfolddemo-app-1  | django.db.utils.OperationalError: SCRAM authentication requires libpq version 10 or above
unfolddemo-app-1  |
unfolddemo-app-1 exited with code 1

@googol7 Interesting indeed - by my quick search - is it possible you are on mac with ARM64? There seems to be some bug, bug, but hard to see that from linux machine on AMD64 :) I tried fresh build/initialisation and seemed to work well.

@PavelPancocha I have a MacBook with an Apple M1 Max CPU.

@googol7 I read some articles - please try it now :) It seems like the M1 can cause some troubles, tried to change some packages. Please do the build again. And I thought the docker will be the best for everyone :)

@PavelPancocha I had to change only one line in requirements.txt to make it work:

-psycopg2-binary==2.9.5
+psycopg2-binary==2.9.3

See:

@PavelPancocha Also with your latest commit it's running now.