Open smithdc1 opened 1 month ago
Hey David,
I had a go at hacking around on this a few days ago. Sorry I didn't write a message until now!
I liked your start, thank you very much. I still want to merge this, and I think it's nearly there. I would prefer to avoid chaining the values_list
onto the queryset in the model iterator branch though, and to only iterate/fetch once. I have some ideas on how to do this, hopefully I'll find some more time again soon.
But until then maybe you can review what I did? I would like another pair of eyes on it, to check I'm not going in a strange direction!
Hi Adam 👋
Reading your edits is a rather valuable learning experience for me. In particular, seeing queryset._iterable_class
was a 'penny drop' moment for me. I didn't know about this and therefore I was writing tests for different queries and seeing what the output was. I learned that I should have been looking at how QuerySet
determines the type of iterable / output.
(I still don't fully understand type hints😄 )
maybe you can review what I did?
Of course! I'm on holiday next week as it's half term here. I'll put it to the top of my list for when I get back.
Fixes #215