# DEP Draft/Request For Shepherd: Unasyncify Codegen

**URL:** <https://forum.djangoproject.com/t/dep-draft-request-for-shepherd-unasyncify-codegen/36038>\
**Category:** Django Internals\
**Created:** [October 29, 2024, 6:39am UTC](https://forum.djangoproject.com/t/dep-draft-request-for-shepherd-unasyncify-codegen/36038 "2024-10-29T06:39:47Z")\
**Posts on this page:** 1\
**Showing post:** 13

<div class="post-metadata">

**Author:** ![rtpg](https://sea2.discourse-cdn.com/flex026/user_avatar/forum.djangoproject.com/rtpg/32/384_2.png) [@rtpg](https://forum.djangoproject.com/u/rtpg)\
**Post date:** [February 14, 2025, 4:14am UTC](https://forum.djangoproject.com/t/dep-draft-request-for-shepherd-unasyncify-codegen/36038/13 "2025-02-14T04:14:20Z")

</div>

Two points:

- For codegen, I have split out the codegen experiment into [its own package](https://django-unasyncify.readthedocs.io/en/latest/) (as `django-unasyncify`). I am going to try and see if I can get any bites in third party apps that might want to try it, but this might be a bit of a failed experiment.

- I have been looking at `async_to_sync` (see [here](https://forum.djangoproject.com/t/an-asgiref-async-to-sync-microbenchmark/38600)), and generally speaking seeing costs that are under a millisecond (often much lower!). If the cost/benefit matrix is acceptable, there might be a “straightforward” answer here of leaning onto `async_to_sync` to offer one canonical async implementation and a sync fallback.

---

_[View the full topic](https://forum.djangoproject.com/t/dep-draft-request-for-shepherd-unasyncify-codegen/36038)._
