plane icon indicating copy to clipboard operation
plane copied to clipboard

[bug]: Migrator script is looping due to an error

Open ronnyandre opened this issue 1 month ago • 0 comments

Is there an existing issue for this?

  • [x] I have searched the existing issues

Current behavior

This happens both when running setup.sh and manually using docker compose.

Using the setup script, starting the applications ends up with this message:

>> Waiting for API Service to Start (300s)............................................................................................................................................................................................................................
   API Service health check timed out after 5 minutes
   Checking if API container is still running...
   API container is running but did not pass the health-check. Continuing without marking it ready.
   ⚠️  API Service did not respond to health-check – please verify manually.
   Plane Server started successfully ✅

   You can access the application at http://localhost

Then the frontend just says:

**Looks like Plane didn't start up correctly!**

Some services might have failed to start. Please check your container logs to identify and resolve the issue. If you're stuck, reach out to our support team for more help.

And checking the logs with docker compose logs -f shows the issue:

migrator-1     | Waiting for database...
migrator-1     | Database available!
migrator-1     | Operations to perform:
migrator-1     |   Apply all migrations: auth, contenttypes, db, django_celery_beat, license, sessions
migrator-1     | Running migrations:
migrator-1     | Traceback (most recent call last):
migrator-1     |   File "/code/manage.py", line 15, in <module>
migrator-1     |     execute_from_command_line(sys.argv)
migrator-1     |   File "/usr/local/lib/python3.12/site-packages/django/core/management/__init__.py", line 442, in execute_from_command_line
migrator-1     |     utility.execute()
migrator-1     |   File "/usr/local/lib/python3.12/site-packages/django/core/management/__init__.py", line 436, in execute
migrator-1     |     self.fetch_command(subcommand).run_from_argv(self.argv)
migrator-1     |   File "/usr/local/lib/python3.12/site-packages/django/core/management/base.py", line 412, in run_from_argv
migrator-1     |     self.execute(*args, **cmd_options)
migrator-1     |   File "/usr/local/lib/python3.12/site-packages/django/core/management/base.py", line 458, in execute
migrator-1     |     output = self.handle(*args, **options)
migrator-1     |              ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
migrator-1     |   File "/usr/local/lib/python3.12/site-packages/django/core/management/base.py", line 106, in wrapper
migrator-1     |     res = handle_func(*args, **kwargs)
migrator-1     |           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^
migrator-1     |   File "/usr/local/lib/python3.12/site-packages/django/core/management/commands/migrate.py", line 356, in handle
migrator-1     |     post_migrate_state = executor.migrate(
migrator-1     |                          ^^^^^^^^^^^^^^^^^
migrator-1     |   File "/usr/local/lib/python3.12/site-packages/django/db/migrations/executor.py", line 135, in migrate
migrator-1     |     state = self._migrate_all_forwards(
migrator-1     |             ^^^^^^^^^^^^^^^^^^^^^^^^^^^
migrator-1     |   File "/usr/local/lib/python3.12/site-packages/django/db/migrations/executor.py", line 167, in _migrate_all_forwards
migrator-1     |     state = self.apply_migration(
migrator-1     |             ^^^^^^^^^^^^^^^^^^^^^
migrator-1     |   File "/usr/local/lib/python3.12/site-packages/django/db/migrations/executor.py", line 252, in apply_migration
migrator-1     |     state = migration.apply(state, schema_editor)
migrator-1     |             ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
migrator-1     |   File "/usr/local/lib/python3.12/site-packages/django/db/migrations/migration.py", line 132, in apply
migrator-1     |     operation.database_forwards(
migrator-1     |   File "/usr/local/lib/python3.12/site-packages/django/db/migrations/operations/models.py", line 659, in database_forwards
migrator-1     |     alter_together(
migrator-1     |   File "/usr/local/lib/python3.12/site-packages/django/db/backends/base/schema.py", line 554, in alter_unique_together
migrator-1     |     self._delete_composed_index(
migrator-1     |   File "/usr/local/lib/python3.12/site-packages/django/db/backends/base/schema.py", line 610, in _delete_composed_index
migrator-1     |     raise ValueError(
migrator-1     | ValueError: Found wrong number (0) of constraints for workspace_user_properties(workspace_id, user_id)
api-1          | Waiting for database migrations to complete...
worker-1       | Waiting for database migrations to complete...
beat-worker-1  | Waiting for database migrations to complete...
migrator-1 exited with code 0

Steps to reproduce

Follow the setup for installing Community Edition.

Environment

Production

Browser

None

Variant

Self-hosted

Version

1.1.0

ronnyandre avatar Nov 25 '25 14:11 ronnyandre