class_docstr: Object for monitoring
  
  Must be child of engine
  
  Handles signal messages and watches Engine process for exiting
class_docstr_tok: ["Object","for","monitoring","Must","be","child","of","engine","Handles","signal","messages","and","watches","Engine","process","for","exiting"]
docstr: Prepare to exit and stop our event loop.
docstr_tok: ["Prepare","to","exit","and","stop","our","event","loop","."]
code: def finish(self):
      """Prepare to exit and stop our event loop."""
      if self._finish_called:
          return
      self._finish_called = True
      self.notify_exit()
      self.loop.add_callback(self.loop.stop)
  
imports: import asyncio
  import logging
  import os
  import pickle
  import signal
  import sys
  from subprocess import PIPE, Popen
  from threading import Thread
  import psutil
  import zmq
  from jupyter_client.session import Session
  from tornado.ioloop import IOLoop
  from traitlets.config import Config
  from zmq.eventloop.zmqstream import ZMQStream
  from ipyparallel import error, util
  from ipyparallel.util import local_logger
label_desc: Use image node_id 5 for calling the KernelNanny obj's underlying member method code with example usage: obj.finish() without return types