608ad092a8d2e14209c803f2da0ed65995d6989d,api/setup.py,,,#,6
Before Change
// code found at: https://stackoverflow.com/a/7071358/6095378
VERSION_FILE = "data_refinery_api/_version.py"
version_line = open(VERSION_FILE, "rt").read()
// The line we"re parsing looks something like:
// __version__ = "1.0.1"
// We want to extract the 1.0.1 part with this regex:
VERSION_REGEX = r"^__version__ = ["\"]([^"\"]*)["\"]"
match_object = re.search(VERSION_REGEX, version_line, re.M)
if match_object:
version_string = match_object.group(1)
else:
raise RuntimeError("Unable to find version string in %s." % (VERSION_FILE,))
setup(
name="data-refinery-api",
version=version_string,
packages=find_packages(),
After Change
os.chdir(os.path.normpath(os.path.join(os.path.abspath(__file__), os.pardir)))
VERSION_FILE = "version"
try:
with open(VERSION_FILE, "rt") as version_file:
version_string = version_file.read().strip()
except:
print("Cannot read version to determine System Version."
" Please create a file api/version containing an up to date System Version.")
raise
setup(
name="data-refinery-api",
version=version_string,
In pattern: SUPERPATTERN
Frequency: 4
Non-data size: 26
Instances
Project Name: AlexsLemonade/refinebio
Commit Name: 608ad092a8d2e14209c803f2da0ed65995d6989d
Time: 2018-09-12
Author: kurt.wheeler91@gmail.com
File Name: api/setup.py
Class Name:
Method Name:
Project Name: AlexsLemonade/refinebio
Commit Name: 608ad092a8d2e14209c803f2da0ed65995d6989d
Time: 2018-09-12
Author: kurt.wheeler91@gmail.com
File Name: foreman/setup.py
Class Name:
Method Name:
Project Name: AlexsLemonade/refinebio
Commit Name: 608ad092a8d2e14209c803f2da0ed65995d6989d
Time: 2018-09-12
Author: kurt.wheeler91@gmail.com
File Name: api/setup.py
Class Name:
Method Name:
Project Name: AlexsLemonade/refinebio
Commit Name: 608ad092a8d2e14209c803f2da0ed65995d6989d
Time: 2018-09-12
Author: kurt.wheeler91@gmail.com
File Name: workers/setup.py
Class Name:
Method Name:
Project Name: AlexsLemonade/refinebio
Commit Name: 608ad092a8d2e14209c803f2da0ed65995d6989d
Time: 2018-09-12
Author: kurt.wheeler91@gmail.com
File Name: common/setup.py
Class Name:
Method Name: