Changes between Initial Version and Version 1 of Ticket #36888, comment 11


Ignore:
Timestamp:
May 29, 2026, 3:51:57 PM (5 days ago)
Author:
Jacob Walls

Legend:

Unmodified
Added
Removed
Modified
  • Ticket #36888, comment 11

    initial v1  
    66}}}
    77
    8 Attempts in the PRs to remove that `sync_to_async()` stalled on the fact that `GenericForeignKeyDescriptor.__set__` accesses the database (see `generic_relations.tests.GenericRelationsTests.test_aadd`).
     8Attempts in the PRs to delegate to `asave()` and push that `sync_to_async()` boundary into `asave()` stalled on the fact that `GenericForeignKeyDescriptor.__set__` accesses the database (see `generic_relations.tests.GenericRelationsTests.test_aadd`). The PRs added another call to `sync_to_async`, which isn't pointing in the right directin, as pointed out in the reviews. (edits: precision)
    99
    10 If we're just shuffling around *where* the `sync_to_async` lies, then we're not accomplishing very much, as pointed out in the reviews. I [https://github.com/django/django/pull/20602#pullrequestreview-4391796527 posted] a sketch of an async interface for Model instantiation.
     10I [https://github.com/django/django/pull/20602#pullrequestreview-4391796527 posted] a sketch of an async interface for Model instantiation.
    1111
    1212I think we need both that ''as well as'' an async implementation of `ContentType` methods (`aget_content_type()` etc.) before we can advance this.
Back to Top