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

    def do_macho(file, bits, endian):
        (cputype, cpusubtype, filetype, ncmds, sizeofcmds, flags) = read_data(file, endian, 6)
        if (bits == 64):
            read_data(file, endian)
        for n in range(ncmds):
            where = file.tell()
            (cmd, cmdsize) = read_data(file, endian, 2)
            if (cmd == LC_LOAD_DYLIB):
                name_offset = read_data(file, endian)
                file.seek((where + name_offset), os.SEEK_SET)
                load = file.read((cmdsize - name_offset)).decode()
                load = load[:load.index('\x00')]
                if (load == what):
                    file.seek((where + name_offset), os.SEEK_SET)
                    file.write((value.encode() + '\x00'.encode()))
            file.seek((where + cmdsize), os.SEEK_SET)
    def do_file(file, offset=0, size=maxint):
        file = fileview(file, offset, size)
        magic = read_data(file, BIG_ENDIAN)
        if (magic == FAT_MAGIC):
            nfat_arch = read_data(file, BIG_ENDIAN)
            for n in range(nfat_arch):
                (cputype, cpusubtype, offset, size, align) = read_data(file, BIG_ENDIAN, 5)
                do_file(file, offset, size)
        elif (magic == MH_MAGIC):
            do_macho(file, 32, BIG_ENDIAN)
        elif (magic == MH_CIGAM):
            do_macho(file, 32, LITTLE_ENDIAN)
        elif (magic == MH_MAGIC_64):
            do_macho(file, 64, BIG_ENDIAN)
        elif (magic == MH_CIGAM_64):
            do_macho(file, 64, LITTLE_ENDIAN)
    assert (len(what) >= len(value))
    with open(path, 'r+b') as f:
        do_file(f)

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

def mach_o_change(path, what, value):