code: def test_emitter_reentrance_allowed_when_blocked3():
      # Like the previous, but blocking callbacks instead of the event itself.
      # Allows more fine-grained control. To some extent anyway - all callbacks
      # of the event must be blocked to prevent raising the emitter loop error.
  
      e1 = EventEmitter(source=None, type="test1")
      e2 = EventEmitter(source=None, type="test2")
      count = 0
  
      @e1.connect
      def foo(x):
          nonlocal count
          count += 1
          with e1.blocker(foo):
              e2()
  
      @e2.connect
      def bar(x):
          nonlocal count
          count += 10
          e1()
  
      @e2.connect
      def eggs(x):
          nonlocal count
          count += 100
          e1()
  
      e1()
      assert count == 111
  
imports: import unittest
  import copy
  import functools
  from vispy.util.event import Event, EventEmitter
  from vispy.testing import run_tests_if_main, assert_raises, assert_equal
label_desc: Use image node_id 5 for calling a global function with example usage: test_emitter_reentrance_allowed_when_blocked3() without return types