TypeError: fromisoformat: argument must be str

This is what it does:

from django.db import migrations, models


class Migration(migrations.Migration):

    dependencies = [
        ('codermatch', '0042_alter_ad_expirationtime'),
    ]

    operations = [
        migrations.AlterField(
            model_name='ad',
            name='projectStartDate',
            field=models.DateField(blank=True, verbose_name='project started (date)'),
        ),
    ]

This is how projectStartDate looks:

class Ad(models.Model):
    ...
    projectStartDate = models.DateField('project started (date)', blank=True)

After deleting several rows in the database, Django now complains about the row 49:

django.db.utils.DataError: (1265, "Data truncated for column 'projectStartDate' at row 49")

And every time I delete a line it complains about another one.

I’ve exported the database from phpmyadmin.
And I’ve deleted the lines in the beginning. So that the line numbers fit the rows.
So row 49 is the one with the NULL value:

Therefore I thought that the NULL value is a problem.

add null=True

I’ve amended the projectStartDate to have null=True:

class Ad(models.Model):
    ...
    projectStartDate = models.DateField('project started (date)', blank=True, null=True)

py manage.py makemigrations results in a new migration:

...
class Migration(migrations.Migration):
...
    operations = [
        migrations.AlterField(
            model_name='ad',
            name='projectStartDate',
            field=models.DateField(blank=True, verbose_name='project started (date)'),
        ),
    ]

delete row 49 (including NULL value)

Then I’ve deleted the object in row 49 from my phpmyadmin.

py manage.py migrate then results in:
django.db.utils.DataError: (1265, "Data truncated for column 'projectStartDate' at row 59")
After deletion of row 49, row 59 is the first one having a NULL for projectStartDate.

If I change the NULL value of row 59 (id 67) to a date (using the calender widget in phpmyadmin) and then running py manage.py migrate again, the output says:
django.db.utils.DataError: (1265, "Data truncated for column 'projectStartDate' at row 62")

As you may presume, row 62 then is the first one in the database with a NULL in projectStartDate.
If I change the value of row 59 back to NULL, the error occurs there again.

Therefore I assume that Django (or MySQL) has a problem with the NULL values now.
But I don’t understand why.
:thinking:Since I’ve just defined null=True, which should make NULL values in the database possible - in my understanding…

By the way

In this case it’s actually not a huge problem.
If I just create a new database (which I can easily do, since I don’t have important data in the database so far) and connect my Django project to this one, I don’t have this issue anymore.

The reason why I am trying to investigate this further is:
I think it’s good to learn how to solve those kind of issues while I am not working with sensitive or important data in a deployed project.
But rather now while I it’s not too much of a problem (actually).
Do you think it’s good to do it and learn it like this?
Or do you think that it’s better to focus on the actual development of the application and solve problems (which might be considered trivial) later😅?