human
I wrote the below code

    args = deque(args)
    nargs_spec = deque(nargs_spec)
    rv = []
    spos = None
    def _fetch(c):
        try:
            if (spos is None):
                return c.popleft()
            else:
                return c.pop()
        except IndexError:
            return None
    while nargs_spec:
        nargs = _fetch(nargs_spec)
        if (nargs == 1):
            rv.append(_fetch(args))
        elif (nargs > 1):
            x = [_fetch(args) for _ in range(nargs)]
            if (spos is not None):
                x.reverse()
            rv.append(tuple(x))
        elif (nargs < 0):
            if (spos is not None):
                raise TypeError('Cannot    have    two    nargs    <    0')
            spos = len(rv)
            rv.append(None)
    if (spos is not None):
        rv[spos] = tuple(args)
        args = []
        rv[(spos + 1):] = reversed(rv[(spos + 1):])
    return (tuple(rv), list(args))

What's a good function header?

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

def _unpack_args(args, nargs_spec):