code: def mkFilter(parts):
      
      # Convert the parts into a list, and pass to mkCompoundFilter
      if parts is None:
          parts = [BasicServiceEndpoint]
  
      try:
          parts = list(parts)
      except TypeError:
          return mkCompoundFilter([parts])
      else:
          return mkCompoundFilter(parts)
docs: Convert a filter-convertable thing into a filter
  
      @param parts: a filter, an endpoint, a callable, or a list of any of these.