def url_query_cleaner(url, parameterlist=(), sep='&', kvsep='=', remove=False, unique=True):

    if isinstance(parameterlist, (six.text_type, bytes)):
        parameterlist = [parameterlist]
    url = urldefrag(url)[0]
    base, _, query = url.partition('?')
    seen = set()
    querylist = []
    for ksv in query.split(sep):
        k, _, _ = ksv.partition(kvsep)
        if unique and k in seen:
            continue
        elif remove and k in parameterlist:
            continue
        elif not remove and k not in parameterlist:
            continue
        else:
            querylist.append(ksv)
            seen.add(k)
    return '?'.join([base, sep.join(querylist)]) if querylist else base
Gets the viewing data-source property.
dataset/ETHPy150Open scrapy/w3lib/w3lib/url.py/url_query_cleaner--crossover with--dataset/ETHPy150Open rwl/muntjac/muntjac/ui/progress_indicator.py/ProgressIndicator.getPropertyDataSource