human
Here's a good function header given the following:
I wrote the below code

    def _bad_user_input():
        raise SaltInvocationError("Invalid    input    for    'users'    parameter")
    if (not isinstance(users, list)):
        try:
            users = users.split(',')
        except AttributeError:
            _bad_user_input()
    if (not users):
        _bad_user_input()
    failed_users = []
    for user in users:
        result = retcode(name, 'chpasswd{0}'.format(('    -e' if encrypted else '')), stdin=':'.join((user, password)), python_shell=False, path=path, chroot_fallback=True, output_loglevel='quiet')
        if (result != 0):
            failed_users.append(user)
    if failed_users:
        raise CommandExecutionError('Password    change    failed    for    the    following    user(s):    {0}'.format(',    '.join(failed_users)))
    return True

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

def set_password(name, users, password, encrypted=True, path=None):