Skip to content

Using an empty string as the default for a ForeignKey is likely to cause issues since it expects an integer or a valid instance reference. Consider using a proper default value (e.g., None or a valid pk) or handling it via a custom migration data migration. #8

Description

@pollardld
          Using an empty string as the default for a ForeignKey is likely to cause issues since it expects an integer or a valid instance reference. Consider using a proper default value (e.g., None or a valid pk) or handling it via a custom migration data migration.
            field=models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, to='layers.layer'),

Originally posted by @Copilot in #7 (comment)

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions