#36815: Avoid unnecessary prepare_value calls when inserting db_defaults
-------------------------------------+-------------------------------------
     Reporter:  Adam Sołtysik        |                    Owner:
         Type:                       |  YashRaj1506
  Cleanup/optimization               |                   Status:  assigned
    Component:  Database layer       |                  Version:  dev
  (models, ORM)                      |
     Severity:  Normal               |               Resolution:
     Keywords:                       |             Triage Stage:  Accepted
    Has patch:  0                    |      Needs documentation:  0
  Needs tests:  0                    |  Patch needs improvement:  0
Easy pickings:  0                    |                    UI/UX:  0
-------------------------------------+-------------------------------------
Comment (by YashRaj1506):

 Replying to [comment:8 Jacob Walls]:
 > Thanks for the benchmark, this seems reasonable. Would you like to
 submit a PR? We can discuss there if we should at least call
 `field_prepare()` once instead of zero times per db-default-field, but
 certainly not N times.
 >
 > (Btw, regarding the flaky test, it's a known issue and is being removed
 in an unrelated PR.)

 Also i want to ask, why are we tyring to run field prepare here? i didnt
 understand that part.
-- 
Ticket URL: <https://code.djangoproject.com/ticket/36815#comment:11>
Django <https://code.djangoproject.com/>
The Web framework for perfectionists with deadlines.

-- 
You received this message because you are subscribed to the Google Groups 
"Django updates" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
To view this discussion visit 
https://groups.google.com/d/msgid/django-updates/0107019b85637943-38cf7ec1-03f9-4a65-a9b2-d6cea9eb10d9-000000%40eu-central-1.amazonses.com.

Reply via email to