Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

New migration created in site-packages #156

Open
mezitax opened this issue May 26, 2020 · 0 comments
Open

New migration created in site-packages #156

mezitax opened this issue May 26, 2020 · 0 comments

Comments

@mezitax
Copy link

mezitax commented May 26, 2020

I am using a multi tenant app, and executing makemigrations generates a new migration in django-categories.

from django.db import migrations, models
import tenant_schemas.storage


class Migration(migrations.Migration):

    dependencies = [
        ('categories', '0004_auto_20200517_1832'),
    ]

    operations = [
        migrations.AlterField(
            model_name='category',
            name='level',
            field=models.PositiveIntegerField(db_index=True, editable=False),
        ),
        migrations.AlterField(
            model_name='category',
            name='lft',
            field=models.PositiveIntegerField(db_index=True, editable=False),
        ),
        migrations.AlterField(
            model_name='category',
            name='rght',
            field=models.PositiveIntegerField(db_index=True, editable=False),
        ),
        migrations.AlterField(
            model_name='category',
            name='thumbnail',
            field=models.FileField(blank=True, null=True, storage=tenant_schemas.storage.TenantFileSystemStorage(), upload_to='uploads/categories/thumbnails'),
        ),
    ]

*The last line is because I have in my settings.py:
DEFAULT_FILE_STORAGE = 'tenant_schemas.storage.TenantFileSystemStorage'

how to avoid new migrations?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant