def METHOD_NAME(view):
    @functools.wraps(view)
    def inner(request, round_id):
        should_cache = not is_contest_admin(request) and not is_contest_observer(
            request
        )
        if not should_cache:
            return view(request, round_id)
        cache_key = '%s/%s/%s' % (view.__name__, request.contest.id, round_id)
        result = cache.get(cache_key)
        if result is None:
            result = view(request, round_id)
            assert isinstance(result, HttpResponse)
            cache.set(
                cache_key,
                {
                    'content': str(result.content),
                    'content_type': result['Content-Type'],
                },
                settings.LIVEDATA_CACHE_TIMEOUT,
            )
        else:
            result = HttpResponse(
                result['content'], content_type=result['content_type']
            )
        return result
    return inner