def update_meta(path, owner, group, filemode):
    if not os.path.exists(path):
        raise ResourceException('This path does not exist.')

    ownerid = get_owner_id(owner)
    groupid = get_group_id(group)
    octfilemode = int(filemode, 8)

    try:
        os.chmod(path, octfilemode)
        os.chown(path, ownerid, groupid)
    except __HOLE__ as err:
        raise ResourceException(err)
dataset/ETHPy150Open comodit/synapse-agent/synapse/resources/files-plugin/unix-files.py/update_meta