trying to gather a collection of objects:
set = [model1].objects.all().filter([model2]__in=[model3].[model2]_set)
but I get a
TypeError at [url]
'ManyRelatedManager' object is not iterable
when I try to do this. Models 2 and 3 are related via a ManyToMany field in Model 2 through a fourth model that has both models as fields.
Any obvious workarounds?
I believe your problem is in
[model2]__in=[model3].[model2]_setthe correct form would be