[Fixed]-Manage.py migration – error

1👍

Your log date field currently has a default of an integer assigned to it, this should be a date.

       migrations.AddField(
                model_name='clienthistory',
                name='log_date',
                field=models.DateTimeField(auto_now_add=True,default=2),  # Change to a date
                preserve_default=False,
        ),

It should also be possible just to remove the default since auto_now_add does that already

👤Sayse

Leave a comment