MCPcopy Create free account
hub / github.com/modelscope/modelscope / _get_pip_version

Function _get_pip_version

modelscope/utils/plugins.py:541–550  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

539 return result
540
541 def _get_pip_version():
542 # try to get pip version without actually importing pip
543 # setuptools gets upset if you import pip before importing setuptools..
544 try:
545 import importlib.metadata # Python 3.8+
546 return importlib.metadata.version('pip')
547 except Exception:
548 pass
549 import pip
550 return pip.__version__
551
552 def _download_dist(url, scratch_file, index_url, extra_index_url):
553 auth = None

Callers 1

_get_wheel_argsFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…