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
taiga-back container failed to execute pending migrations if a PostgreSQL container exists in the same namespace with a service named postgres.
Output Log
Executing pending migrations
Traceback (most recent call last):
File "/opt/venv/lib/python3.11/site-packages/django/db/backends/base/base.py", line 219, in ensure_connection
self.connect()
File "/opt/venv/lib/python3.11/site-packages/django/utils/asyncio.py", line 33, in inner
return func(*args, **kwargs)
^^^^^^^^^^^^^^^^^^^^^
File "/opt/venv/lib/python3.11/site-packages/django/db/backends/base/base.py", line 200, in connect
self.connection = self.get_new_connection(conn_params)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/opt/venv/lib/python3.11/site-packages/django/utils/asyncio.py", line 33, in inner
return func(*args, **kwargs)
^^^^^^^^^^^^^^^^^^^^^
File "/opt/venv/lib/python3.11/site-packages/django/db/backends/postgresql/base.py", line 187, in get_new_connection
connection = Database.connect(**conn_params)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/opt/venv/lib/python3.11/site-packages/psycopg2/__init__.py", line 122, in connect
conn = _connect(dsn, connection_factory=connection_factory, **kwasync)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
psycopg2.OperationalError: invalid integer value "tcp://10.100.143.147:5432" for connection option "port"
The above exception was the direct cause of the following exception:
Traceback (most recent call last):
File "/taiga-back/manage.py", line 17, in <module>
execute_from_command_line(sys.argv)
File "/opt/venv/lib/python3.11/site-packages/django/core/management/__init__.py", line 419, in execute_from_command_line
utility.execute()
File "/opt/venv/lib/python3.11/site-packages/django/core/management/__init__.py", line 413, in execute
self.fetch_command(subcommand).run_from_argv(self.argv)
File "/opt/venv/lib/python3.11/site-packages/django/core/management/base.py", line 354, in run_from_argv
self.execute(*args, **cmd_options)
File "/opt/venv/lib/python3.11/site-packages/django/core/management/base.py", line 398, in execute
output = self.handle(*args, **options)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/opt/venv/lib/python3.11/site-packages/django/core/management/base.py", line 89, in wrapped
res = handle_func(*args, **kwargs)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/opt/venv/lib/python3.11/site-packages/django/core/management/commands/migrate.py", line 75, in handle
self.check(databases=[database])
File "/opt/venv/lib/python3.11/site-packages/django/core/management/base.py", line 419, in check
all_issues = checks.run_checks(
^^^^^^^^^^^^^^^^^^
File "/opt/venv/lib/python3.11/site-packages/django/core/checks/registry.py", line 76, in run_checks
new_errors = check(app_configs=app_configs, databases=databases)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/opt/venv/lib/python3.11/site-packages/django/core/checks/model_checks.py", line 34, in check_all_models
errors.extend(model.check(**kwargs))
^^^^^^^^^^^^^^^^^^^^^
File "/opt/venv/lib/python3.11/site-packages/django/db/models/base.py", line 1303, in check
*cls._check_indexes(databases),
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/opt/venv/lib/python3.11/site-packages/django/db/models/base.py", line 1695, in _check_indexes
connection.features.supports_covering_indexes or
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/opt/venv/lib/python3.11/site-packages/django/utils/functional.py", line 48, in __get__
res = instance.__dict__[self.name] = self.func(instance)
^^^^^^^^^^^^^^^^^^^
File "/opt/venv/lib/python3.11/site-packages/django/db/backends/postgresql/features.py", line 92, in is_postgresql_11
return self.connection.pg_version >= 110000
^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/opt/venv/lib/python3.11/site-packages/django/utils/functional.py", line 48, in __get__
res = instance.__dict__[self.name] = self.func(instance)
^^^^^^^^^^^^^^^^^^^
File "/opt/venv/lib/python3.11/site-packages/django/db/backends/postgresql/base.py", line 329, in pg_version
with self.temporary_connection():
File "/usr/local/lib/python3.11/contextlib.py", line 137, in __enter__
return next(self.gen)
^^^^^^^^^^^^^^
File "/opt/venv/lib/python3.11/site-packages/django/db/backends/base/base.py", line 603, in temporary_connection
with self.cursor() as cursor:
^^^^^^^^^^^^^
File "/opt/venv/lib/python3.11/site-packages/django/utils/asyncio.py", line 33, in inner
return func(*args, **kwargs)
^^^^^^^^^^^^^^^^^^^^^
File "/opt/venv/lib/python3.11/site-packages/django/db/backends/base/base.py", line 259, in cursor
return self._cursor()
^^^^^^^^^^^^^^
File "/opt/venv/lib/python3.11/site-packages/django/db/backends/base/base.py", line 235, in _cursor
self.ensure_connection()
File "/opt/venv/lib/python3.11/site-packages/django/utils/asyncio.py", line 33, in inner
return func(*args, **kwargs)
^^^^^^^^^^^^^^^^^^^^^
File "/opt/venv/lib/python3.11/site-packages/django/db/backends/base/base.py", line 218, in ensure_connection
with self.wrap_database_errors:
File "/opt/venv/lib/python3.11/site-packages/django/db/utils.py", line 90, in __exit__
raise dj_exc_value.with_traceback(traceback) from exc_value
File "/opt/venv/lib/python3.11/site-packages/django/db/backends/base/base.py", line 219, in ensure_connection
self.connect()
File "/opt/venv/lib/python3.11/site-packages/django/utils/asyncio.py", line 33, in inner
return func(*args, **kwargs)
^^^^^^^^^^^^^^^^^^^^^
File "/opt/venv/lib/python3.11/site-packages/django/db/backends/base/base.py", line 200, in connect
self.connection = self.get_new_connection(conn_params)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/opt/venv/lib/python3.11/site-packages/django/utils/asyncio.py", line 33, in inner
return func(*args, **kwargs)
^^^^^^^^^^^^^^^^^^^^^
File "/opt/venv/lib/python3.11/site-packages/django/db/backends/postgresql/base.py", line 187, in get_new_connection
connection = Database.connect(**conn_params)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/opt/venv/lib/python3.11/site-packages/psycopg2/__init__.py", line 122, in connect
conn = _connect(dsn, connection_factory=connection_factory, **kwasync)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
django.db.utils.OperationalError: invalid integer value "tcp://10.100.143.147:5432" for connection option "port"
Describe the bug
taiga-back
container failed to execute pending migrations if a PostgreSQL container exists in the same namespace with a service namedpostgres
.Output Log
How can we reproduce the behavior
Using
minikube
, apply the following YAML:test.yaml
Workarounds
POSTGRES_PORT=5432
to the list of environment variables, orTaiga environment
Desktop (please complete the following information):
Additional context
This bug is only observed in Kubernetes.
The text was updated successfully, but these errors were encountered: