code: def test_cancel_future(backend):
      with BatchPoolExecutor(
          backend=backend, project="hail-vdc", image=PYTHON_DILL_IMAGE
      ) as bpe:
  
          def sleep_forever():
              while True:
                  time.sleep(3600)
  
          future = bpe.submit(sleep_forever)
          was_cancelled = future.cancel()
      assert was_cancelled
      assert future.cancelled()
  
imports: import asyncio
  import time
  import pytest
  from hailtop.batch import BatchPoolExecutor, ServiceBackend
  from hailtop.config import get_user_config
  from hailtop.utils import sync_sleep_before_try
  from hailtop.batch_client.client import BatchClient
label_desc: Use image node_id 6 for calling a global function with example usage: test_cancel_future(backend) without return types