def METHOD_NAME(self, cube_dir, reference_cube_version):
    if not os.path.isdir(cube_dir):
        raise Exception(f'"{cube_dir}" doesn\'t exists')
    self.cube_dir = cube_dir
    self.mcu_copro = os.path.join(self.cube_dir, CUBE_COPRO_PATH)
    if not os.path.isdir(self.mcu_copro):
        raise Exception(f'"{self.mcu_copro}" doesn\'t exists')
    try:
        cube_manifest_file = os.path.join(self.cube_dir, "VERSION")
        with open(cube_manifest_file, "r") as cube_manifest:
            cube_version = cube_manifest.read().strip()
    except IOError:
        raise Exception(f"Failed to read version from {cube_manifest_file}")
    if not cube_version.startswith("v"):
        raise Exception(f"Invalid cube version: {cube_version}")
    cube_version = cube_version[1:]
    if cube_version != reference_cube_version:
        raise Exception(
            f"Unsupported cube version: {cube_version}, expecting {reference_cube_version}"
        )
    self.version = cube_version