code: def update_event_and_problem_id(self):
          
          ok_up = self.__class__.ok_up  # OK for service, UP for host
          if (self.state != self.last_state and self.last_state != 'PENDING' or
                  self.state != ok_up and self.last_state == 'PENDING'):
              SchedulingItem.current_event_id += 1
              self.last_event_id = self.current_event_id
              self.current_event_id = SchedulingItem.current_event_id
              # now the problem_id
              if self.state != ok_up and self.last_state == 'PENDING':
                  # broken ever since i can remember
                  SchedulingItem.current_problem_id += 1
                  self.last_problem_id = self.current_problem_id
                  self.current_problem_id = SchedulingItem.current_problem_id
              elif ok_up not in (self.state, self.last_state):
                  # State transitions between non-OK states
                  # (e.g. WARNING to CRITICAL) do not cause
                  # this problem id to increase.
                  pass
              elif self.state == ok_up:
                  # If the service is currently in an OK state,
                  # this macro will be set to zero (0).
                  self.last_problem_id = self.current_problem_id
                  self.current_problem_id = 0
              else:
                  # Every time a service (or host) transitions from
                  # an OK or UP state to a problem state, a global
                  # problem ID number is incremented by one (1).
                  SchedulingItem.current_problem_id += 1
                  self.last_problem_id = self.current_problem_id
                  self.current_problem_id = SchedulingItem.current_problem_id
docs: Update current_event_id and current_problem_id
          Those attributes are used for macros (SERVICEPROBLEMID ...)
  
          :return: None