DEP Draft/Request For Shepherd: Unasyncify Codegen

Summarizing some chatter from Discord:

  • Might be interesting to try and apply this codegen to a third party library willing to offer itself up as a sacrifice and to “prove the point” about this being feasible (my ideas on this: django-ninja perhaps? Or just look up a list of packages that use asgiref, since pervasive usage of sync_to_async and async_to_sync might be indicative of missing something here)

  • unasync exists as an alternative package that does something similar. Instead of inline code editing, it generates separate files. I like being able to generate stuff inline next to each other because of how easy it is to see stuff be in sync… and also for the ORM at least we want two methods on the same class, not two classes outright. But maybe unasync’s strategy is cleaner…

  • @steering_council this is the lightest possible ping on this DEP, since I had originally posted it right before the previous steering council disbanded.