code: def _get_current_minute(self):
          
  
          dt = self.datetime
  
          if self._adjust_minutes:
              dt = \
                  self.data_portal.trading_calendar.previous_minute(dt)
  
          if self._daily_mode:
              # if we're in daily mode, take the given dt (which is the last
              # minute of the session) and get the session label for it.
              dt = self.data_portal.trading_calendar.minute_to_session_label(dt)
  
          return dt
docs: Internal utility method to get the current simulation time.
  
          Possible answers are:
          - whatever the algorithm's get_datetime() method returns (this is what
              `self.simulation_dt_func()` points to)
          - sometimes we're knowingly not in a market minute, like if we're in
              before_trading_start.  In that case, `self._adjust_minutes` is
              True, and we get the previous market minute.
          - if we're in daily mode, get the session label for this minute.