# Generated by Django 3.2.19 on 2024-06-03 15:20

from django.db import migrations, models

import debusine.tasks.models


class Migration(migrations.Migration):

    dependencies = [
        ('db', '0064_worker_worker_type_data'),
    ]

    operations = [
        migrations.RemoveConstraint(
            model_name='worker',
            name='db_worker_celery_or_token',
        ),
        migrations.RemoveField(
            model_name='worker',
            name='internal',
        ),
        migrations.AddConstraint(
            model_name='worker',
            constraint=models.CheckConstraint(
                check=models.Q(
                    ('worker_type', debusine.tasks.models.WorkerType['CELERY']),
                    ('token__isnull', False),
                    _connector='OR',
                ),
                name='db_worker_celery_or_token',
            ),
        ),
    ]
