human
I wrote the below code

    def desc_iter(**kwargs):
        for d in desc:
            tests = ((val == getattr(d, key)) for (key, val) in kwargs.items())
            if (_interop._all(tests) and ((custom_match is None) or custom_match(d))):
                (yield d)
    if find_all:
        return desc_iter(**args)
    else:
        try:
            return _interop._next(desc_iter(**args))
        except StopIteration:
            return None

What's a good function header?
 ... Here's a good function header?
assistant
#Here's a good function header.

def find_descriptor(desc, find_all=False, custom_match=None, **args):