5 | | Just checking to see if the current state of Django lent itself to any of the proposed ideas here (setting to greedily load / async-compatible function / greenlets / something else)? I'd be keen to have a crack at this but wanted to see what the best approach might be before doing a deep dive on a badly chosen one. |
| 5 | Just checking to see if the current state of Django lent itself to any of the proposed ideas here (setting to greedily load / async-compatible function / greenlets / something else)? I'd be keen to have a crack at this but wanted to see what the best approach might be before doing a deep dive on a badly chosen one. Given the above choices I guess my next questions would be: |
| 6 | |
| 7 | 1. For the greedy load, I would imagine the greedy load would be for all of the middleware? I think `AuthenticationMiddleware` is the only one that lazy loads an object (although `GZipMiddleware` has a `_lazy_re_compile` which I've not wrapped my head around yet to know if that would need to be updated too). |
| 8 | |
| 9 | 2. The user / `SimpleLazyObject` async function sounds like it might potentially be the neatest, but I don't really understand how that could be implemented. Do you have any existing examples that so similar things (or even just a pointer of how I might approach this)? |
| 10 | |
| 11 | 3. I've not encountered "greenlets" before. Are you referencing this library? https://github.com/python-greenlet/greenlet |