Changes between Version 1 and Version 2 of Ticket #31071


Ignore:
Timestamp:
Dec 6, 2019, 9:56:25 AM (5 years ago)
Author:
Reupen Shah
Comment:

Legend:

Unmodified
Added
Removed
Modified
  • Ticket #31071 – Description

    v1 v2  
    22
    33{{{
     4from uuid import uuid4
     5
     6from django.db import models
     7
    48class Sample(models.Model):
    59    id = models.UUIDField(primary_key=True, default=uuid4)
     
    1620
    1721
    18 However, in Django 3.0, this results in two INSERTs (naturally the second one fails). The behaviour also changes if the `id` field `default` is removed.
     22However, in Django 3.0, this results in two INSERTs (naturally the second one fails). The behaviour also changes if `default=uuid4` is removed from the `id` field.
    1923
    2024This seems related to https://code.djangoproject.com/ticket/29260.
Back to Top