MCPcopy Create free account
hub / github.com/YesianRohn/TextSSR / get_version

Function get_version

diffusers/utils/release.py:97–102  ·  view source on GitHub ↗

Reads the current version in the __init__.

()

Source from the content-addressed store, hash-verified

95
96
97def get_version():
98 """Reads the current version in the __init__."""
99 with open(REPLACE_FILES["init"], "r") as f:
100 code = f.read()
101 default_version = REPLACE_PATTERNS["init"][0].search(code).groups()[0]
102 return packaging.version.parse(default_version)
103
104
105def pre_release_work(patch=False):

Callers 2

pre_release_workFunction · 0.85
post_release_workFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected