class_docstr: Protocol is the base class that other protocols in TF Encrypted will extend.
  
  Do not directly instantiate this class.  You should use a subclass instead,
  such as :class:`~tf_encrypted.protocol.protocol.SecureNN`
  or :class:`~tf_encrypted.protocol.protocol.Pond`
code: def __exit__(
      self,
      exception_type,
      exception_value: Optional[Exception],
      traceback: Optional[TracebackType],
  ) -> Optional[bool]:
      tfe.set_protocol(self.last_protocol)
  
imports: import functools
  from abc import ABC
  from types import TracebackType
  from typing import Any
  from typing import Callable
  from typing import Optional
  import tensorflow
  import tf_encrypted
  from ..config import get_config
  from ..tensor.factory import AbstractTensor
label_desc: Use image node_id 2 for calling the Protocol obj's underlying member method code with example usage: obj.__exit__(exception_type, exception_value, traceback) without return types