MCPcopy Create free account
hub / github.com/OpenNMT/CTranslate2 / _get_project_version

Function _get_project_version

python/setup.py:23–28  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

21
22
23def _get_project_version():
24 version_path = os.path.join(base_dir, "ctranslate2", "version.py")
25 version = {}
26 with open(version_path, encoding="utf-8") as fp:
27 exec(fp.read(), version)
28 return version["__version__"]
29
30
31def _maybe_add_library_root(lib_name):

Callers 1

setup.pyFile · 0.85

Calls 1

joinMethod · 0.80

Tested by

no test coverage detected