Skip to content

Commit

Permalink
Merge pull request #153 from leukeleu/big-auto-field
Browse files Browse the repository at this point in the history
Fixed #152 -- Migrate to BigAutoField
  • Loading branch information
spookylukey committed Nov 4, 2021
2 parents 035b518 + a1c4100 commit e948676
Show file tree
Hide file tree
Showing 3 changed files with 35 additions and 0 deletions.
1 change: 1 addition & 0 deletions CHANGES.rst
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,7 @@ Change log
2.1.1 - Unreleased
------------------

* Migrate models ``id`` fields to ``BigAutoField``.
* Add ``runmailer`` management command. This command starts a loop that
frequently checks the database for new emails. The wait time between
checks can be controlled using the ``MAILER_EMPTY_QUEUE_SLEEP`` setting.
Expand Down
6 changes: 6 additions & 0 deletions src/mailer/apps.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
from django.apps import AppConfig


class MailerConfig(AppConfig):
name = 'mailer'
default_auto_field = 'django.db.models.BigAutoField'
28 changes: 28 additions & 0 deletions src/mailer/migrations/0005_id_bigautofield.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,28 @@
# Generated by Django 3.2.9 on 2021-11-04 13:31

from django.db import migrations, models


class Migration(migrations.Migration):

dependencies = [
('mailer', '0004_auto_20190920_1512'),
]

operations = [
migrations.AlterField(
model_name='dontsendentry',
name='id',
field=models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID'),
),
migrations.AlterField(
model_name='message',
name='id',
field=models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID'),
),
migrations.AlterField(
model_name='messagelog',
name='id',
field=models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID'),
),
]

0 comments on commit e948676

Please sign in to comment.