@staticmethod
def _filepath_assign_edits(block, path, filepath, binary_edits):
    """
        Record the write to a separate entry (binary file-like object),
        this lets us replay the edits later.
        (so we can replay them onto the clients local cache without a file transfer).
        """
    import struct
    assert type(filepath) is bytes
    assert type(path) is bytes
    ofs, size = block.get_file_offset(path)
    filepath = filepath[:size - 1]
    binary_edits.append((ofs, filepath + b'\x00'))
