code: def test_sync(client):
      counter = client.submit(Counter, actor=True)
      counter = counter.result()
  
      assert counter.n == 0
  
      future = counter.increment()
      n = future.result()
      assert n == 1
      assert counter.n == 1
  
      assert future.result() == future.result()
  
      assert "ActorFuture" in repr(future)
      assert "distributed.actor" not in repr(future)
  
imports: from __future__ import annotations
  import asyncio
  import operator
  from time import sleep
  import pytest
  import dask
  from distributed import Actor, BaseActorFuture, Client, Future, Nanny, as_completed, get_client, wait, worker_client
  from distributed.metrics import time
  from distributed.utils import LateLoopEvent
  from distributed.utils_test import cluster, double, gen_cluster, inc
  from distributed.worker import get_worker
label_desc: Use image node_id 1 for calling a global function with example usage: test_sync(client) without return types