Hi, I'm trying to run the command 'python manage.py migrate auth' but im getting this error 'django.db.utils.OperationalError: (1067, "Invalid default value for 'date_joined'")'.
I'm using Django 3.2.9 and MySQL 8.0.32-0ubuntu0.22.04.2. I changed the sql config altering the sql_mode variable but I'm getting the same error.
The declaration of the field date_joined is the default of django instalation
date_joined = models.DateTimeField(_('date joined'), default=timezone.now)
You received this message because you are subscribed to the Google Groups "Django users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to django-users+unsubscribe@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/django-users/19fa95b0-0e82-49d2-9007-b36bae8f770en%40googlegroups.com.
No comments:
Post a Comment