

def handle(self, *args, **options):
    '\n        Script that calls all season pages to refresh the cache on them if it has expired.\n\n        Any time/date settings create postfixes on the caching key, for now the solution is to disable them.\n        '
    if settings.USE_I18N:
        raise CommandError('USE_I18N in settings must be disabled.')
    if settings.USE_L10N:
        raise CommandError('USE_L10N in settings must be disabled.')
    if settings.USE_TZ:
        raise CommandError('USE_TZ in settings must be disabled.')
    self.factory = RequestFactory()
    seasons = Season.objects.all()
    for season in self:
        path = reverse('ladder:season', args=(unicode(season.end_date.year), unicode(season.season_round)))
        request = self.factory.get(path)
        season_view(request, season.end_date.year, season.season_round)

dataset/ETHPy150Open jzahedieh/django-tennis-ladder/ladder/management/commands/refresh_cache.py Command.handle/VarMisuse@81/221 `seasons`->`self`