code: def getLocalDatetime(date, time, tz=None, timeDefault=dt.time.max):
      
      localTZ = timezone.get_current_timezone()
      if tz is None or tz == localTZ:
          localDt = getAwareDatetime(date, time, tz, timeDefault)
      else:
          # create in event's time zone
          eventDt = getAwareDatetime(date, time, tz, timeDefault)
          # convert to local time zone
          localDt = eventDt.astimezone(localTZ)
          if time is None:
              localDt = getAwareDatetime(localDt.date(), None, localTZ, timeDefault)
      return localDt
docs: Get a datetime in the local timezone from date and optionally time