code: def test_dag_exception(ray_start_regular, capsys):
      a = Actor.remote(0)
      with InputNode() as inp:
          dag = a.inc.bind(inp)
  
      compiled_dag = dag.experimental_compile()
      output_channel = compiled_dag.execute("hello")
      with pytest.raises(TypeError):
          output_channel.begin_read()
      output_channel.end_read()
  
      # Can do it multiple times.
      output_channel = compiled_dag.execute("hello")
      with pytest.raises(TypeError):
          output_channel.begin_read()
  
      compiled_dag.teardown()
  
imports: import logging
  import os
  import random
  import sys
  import time
  import pytest
  import ray
  import ray.cluster_utils
  from ray.exceptions import RaySystemError
  from ray.dag import InputNode, MultiOutputNode
  from ray.tests.conftest import *
label_desc: Use image node_id 5 for calling a global function with example usage: test_dag_exception(ray_start_regular, capsys) without return types