parameters: (self)
docstring: Context manager to request stop when an Exception is raised.
  
      Code that uses a coordinator must catch exceptions and pass
      them to the `request_stop()` method to stop the other threads
      managed by the coordinator.
  
      This context handler simplifies the exception handling.
      Use it as follows:
  
      ```python
      with coord.stop_on_exception():
        # Any exception raised in the body of the with
        # clause is reported to the coordinator before terminating
        # the execution of the body.
        ...body...
      ```
  
      This is completely equivalent to the slightly longer code:
  
      ```python
      try:
        ...body...
      exception Exception as ex:
        coord.request_stop(ex)
      ```
  
      Yields:
        nothing.
docstring_summary: Context manager to request stop when an Exception is raised.
docstring_tokens: Context manager to request stop when an Exception is raised .
function: def stop_on_exception(self):
      """Context manager to request stop when an Exception is raised.
  
      Code that uses a coordinator must catch exceptions and pass
      them to the `request_stop()` method to stop the other threads
      managed by the coordinator.
  
      This context handler simplifies the exception handling.
      Use it as follows:
  
      ```python
      with coord.stop_on_exception():
        # Any exception raised in the body of the with
        # clause is reported to the coordinator before terminating
        # the execution of the body.
        ...body...
      ```
  
      This is completely equivalent to the slightly longer code:
  
      ```python
      try:
        ...body...
      exception Exception as ex:
        coord.request_stop(ex)
      ```
  
      Yields:
        nothing.
      """
      # pylint: disable=broad-except
      try:
        yield
      except Exception as ex:
        self.request_stop(ex)
function_tokens: def stop_on_exception ( self ) : # pylint: disable=broad-except try : yield except Exception as ex : self . request_stop ( ex )