async def METHOD_NAME(
    dependencies: List[DependencyInfo],
    update_progress_cb: Optional[UpdateProgressFn] = None,
    logger: Optional[Logger] = None,
):
    # If there's no progress callback, just install the dependencies synchronously
    if update_progress_cb is None:
        install_dependencies_sync(dependencies)
        return
    dependencies_to_install = get_deps_to_install(dependencies)
    if len(dependencies_to_install) == 0:
        return
    dependency_name_map = {
        dep_info["package_name"]: dep_info["display_name"]
        for dep_info in dependencies_to_install
    }
    deps_count = len(dependencies_to_install)
    deps_counter = 0
    transitive_deps_counter = 0
    DEP_MAX_PROGRESS = 0.8
    def get_progress_amount():
        transitive_progress = 1 - 1 / (2**transitive_deps_counter)
        progress = (deps_counter + transitive_progress) / (deps_count + 1)
        return min(max(0, progress), 1) * DEP_MAX_PROGRESS
    # Used to increment by a small amount between collect and download
    dep_small_incr = (DEP_MAX_PROGRESS / deps_count) / 2
    process = subprocess.Popen(
        [
            python_path,
            "-m",
            # TODO: Change this back to "pip" once pip updates with my changes
            "chainner_pip",
            "install",
            *[pin(dep_info) for dep_info in dependencies_to_install],
            "--disable-chainner_pip-version-check",
            "--no-warn-script-location",
            "--progress-bar=json",
        ],
        stdout=subprocess.PIPE,
        stderr=subprocess.STDOUT,
    )
    installing_name = "Unknown"
    while True:
        nextline = process.stdout.readline()  # type: ignore
        if nextline == b"" and process.poll() is not None:
            break
        line = nextline.decode("utf-8").strip()
        if logger is not None and not line.startswith("Progress:"):
            logger.info(line)
        # The Collecting step of pip. It tells us what package is being installed.
        if "Collecting" in line:
            match = COLLECTING_REGEX.search(line)
            if match:
                package_name = match.group(1)
                installing_name = dependency_name_map.get(package_name, None)
                if installing_name is None:
                    installing_name = package_name
                    transitive_deps_counter += 1
                else:
                    deps_counter += 1
                await update_progress_cb(
                    f"Collecting {installing_name}...", get_progress_amount(), None
                )
        # The Downloading step of pip. It tells us what package is currently being downloaded.
        # Later, we can use this to get the progress of the download.
        # For now, we just tell the user that it's happening.
        elif "Downloading" in line:
            await update_progress_cb(
                f"Downloading {installing_name}...",
                get_progress_amount() + dep_small_incr,
                None,
            )
        # We can parse this line to get the progress of the download, but only in our pip fork for now
        elif "Progress:" in line:
            json_line = line.replace("Progress:", "").strip()
            try:
                parsed = json.loads(json_line)
                current, total = parsed["current"], parsed["total"]
                if total is not None and total > 0:
                    percent = current / total
                    await update_progress_cb(
                        f"Downloading {installing_name}...",
                        get_progress_amount() + dep_small_incr,
                        percent,
                    )
            except Exception as e:
                if logger is not None:
                    logger.error(str(e))
                # pass
        # The Installing step of pip. Installs happen for all the collected packages at once.
        # We can't get the progress of the installation, so we just tell the user that it's happening.
        elif "Installing collected packages" in line:
            await update_progress_cb(f"Installing collected dependencies...", 0.9, None)
    exit_code = process.wait()
    if exit_code != 0:
        raise ValueError("An error occurred while installing dependencies.")
    await update_progress_cb(f"Finished installing dependencies...", 1, None)
    for dep_info in dependencies_to_install:
        installing_name = dep_info["package_name"]
        version = dep_info["version"]
        installed_packages[installing_name] = version