docs: def get_files(cls, file_pattern, nb_previous_files, from_date=None):
          """
          Return an :class:`~taxi.utils.structures.OrderedSet` of file paths expanded from `filename`, with a maximum of
          `nb_previous_files`. See :func:`taxi.utils.file.expand_date` for more information about filename expansion. If
          `from_date` is set, it will be used as a starting date instead of the current date.
          """
          date_units = ['m', 'Y']
          smallest_unit = None
  
          if not from_date:
              from_date = datetime.date.today()
  
          for date_unit in date_units:
              if ('%' + date_unit) in file_pattern:
                  smallest_unit = date_unit
                  break
  
          if smallest_unit is None:
              return OrderedSet([file_pattern])
  
          files = OrderedSet()
  
          for i in range(nb_previous_files, -1, -1):
              if smallest_unit == 'm':
                  file_date = months_ago(from_date, i)
              elif smallest_unit == 'Y':
                  file_date = from_date.replace(day=1, year=from_date.year - i)
  
              files.add(file_utils.expand_date(file_pattern, file_date))
  
          return files