I'm new to django so this must be a silly question but i was working my way through the official documentation tutorial(the one about a site with polls and choices) and i wanted to filter out polls with no choices, i managed to do that with a filter in the queryset argument of the ListView:
queryset=Poll.objects.filter(pub_date__lte=timezone.now).filter(id__in=Choice.objects.all).order_by('-pub_date')[:5]
And this indeed filters the query, the problem is that if i add a choice to a poll that didn't have any choices from the admin site, this won't be reflected on the site until i restart the server or i change some code in the project, even though i'm passing a callable object as argument to the filter (which is the same as the previous filter in that same line), i searched in the rest of documentation and i also looked at the definitive guide to django but i found nothing, that could help me, so i don't really know if there's something wrong with the code, or i'm lacking some understanding of django or a particular concept of python itself