code: def _get_non_empty_list(cls, iter):
          
          res = []
          for value in iter:
              if hasattr(value, 'items'):
                  value = cls._get_non_empty_dict(value) or None
              if value is not None:
                  res.append(value)
          return res
docs: Return a list of the input, excluding all ``None`` values.