kedro.framework.cli.utils.get_pkg_version — Kedro 0.17.6 documentation

# kedro.framework.cli.utils.get_pkg_version

`kedro.framework.cli.utils.` `get_pkg_version`(reqs_path, package_name)

  Get package version from requirements.txt.

  Parameters

    - reqs_path (`Union`[`str`, `Path`]) – Path to requirements.txt file.

    - package_name (`str`) – Package to search for.

  Return type

    `str`

  Returns

    Package and its version as specified in requirements.txt.

  Raises

    KedroCliError – If the file specified in `reqs_path` does not exist or `package_name` was not found in that file.