docs: def get_session(self, create=True):
          """
          :type create:  bool
          """
          msg = ("{0} attempting to get session; create = {1}; \'session is None\' ="
                 "{2} ; \'session has id\' = {3}".
                 format(self.__class__.__name__, create, (self.session is None), str(
                        self.session is not None and bool(self.session.session_id))))
          logger.debug(msg)
  
          if self.session and not create:  # touching a new session is redundant
              self.session.touch()  # this is used to reset the idle timer (new to yosai)
              return self.session
  
          if (not self.session and create):
              if (not self.is_session_creation_enabled()):
                  msg = ("Session creation is disabled for the current subject. "
                         "This exception indicates that there is "
                         "either a programming error (using a session when "
                         "it should never be used) or that Yosai's "
                         "configuration needs to be adjusted to allow "
                         "Sessions to be created for the current Subject.")
                  raise ValueError(msg)
  
              msg = ("Starting session for host ", str(self.host))
              logger.debug(msg)
  
              session_context = self.create_session_context()
              session = self.security_manager.start(session_context)
              session.stop_session_callback = self.session_stopped
              self.session = session
  
          return self.session