def remove_tag(request, run_ids, tags):
    """Remove a tag from a run.

    :param run_ids: give one or more run IDs. It could be an integer, a
        string containing comma separated IDs, or a list of int each of them is
        a run ID.
    :type run_ids: int, str or list
    :param tags: tag name or a list of tag names to remove.
    :type tags: str or list
    :return: a list which is empty on success.
    :rtype: list

    Example::

        # Remove tag 'foo' from run 1
        TestRun.remove_tag(1, 'foo')
        # Remove tag 'foo' and 'bar' from run list [1, 2]
        TestRun.remove_tag([1, 2], ['foo', 'bar'])
        # Remove tag 'foo' and 'bar' from run list '1, 2' with String
        TestRun.remove_tag('1, 2', 'foo, bar')
    """
    trs = TestRun.objects.filter(run_id__in=pre_process_ids(value=run_ids))
    tgs = TestTag.objects.filter(name__in=TestTag.string_to_list(tags))

    tr: TestRun
    for tr in trs.iterator():
        for tg in tgs.iterator():
            tr.remove_tag(tag=tg)