942f284052b22214d830c1bc2c8de03bffaa8d07,build_tools/azure/render_meta.py,,,#,8

Before Change


    requirements = [line.strip() for line in file.readlines()]

// We build from source on windows, otherwise, we looks for a wheel
if sys.platform != "win32":
    wheel = next(file for file in os.listdir(str(DIST_PATH.resolve()))
                 if file.endswith(".whl"))
else:
    wheel = None

// Numpy version is used for building
numpy_version = next(package for package in requirements if "numpy" in package)

// Render and write the meta.yaml file to $ROOT/conda/meta.yaml
context = {

After Change


with open(str(REQUIREMENTS_FILE.resolve())) as file:
    for line in file:
        requirement = line.strip()
        match = re.match(r"^([A-Za-z\-0-9]+)", requirement)
        _, match_end = match.span()
        package = match.group(0)
        version = requirement[match_end:].replace("==", "")
        requirements.append(f"{package} {version}")

// Render and write the meta.yaml file to $ROOT/conda/meta.yaml
Italian Trulli
In pattern: SUPERPATTERN

Frequency: 4

Non-data size: 6

Instances


Project Name: tgsmith61591/pmdarima
Commit Name: 942f284052b22214d830c1bc2c8de03bffaa8d07
Time: 2020-02-18
Author: aaronreidsmith@gmail.com
File Name: build_tools/azure/render_meta.py
Class Name:
Method Name:


Project Name: pantsbuild/pants
Commit Name: ef7964296ee8d5025dbdf7ca02eddd72a8b9df56
Time: 2020-07-23
Author: 14852634+Eric-Arellano@users.noreply.github.com
File Name: src/python/pants/backend/codegen/protobuf/protoc.py
Class Name: Protoc
Method Name: generate_url


Project Name: pantsbuild/pants
Commit Name: 555363bd1809fa6acd15e3e61f0a45a38c1ca7d5
Time: 2019-12-14
Author: 1305167+cosmicexplorer@users.noreply.github.com
File Name: tests/python/pants_test/base/test_exception_sink.py
Class Name: TestExceptionSink
Method Name: test_set_invalid_log_location


Project Name: fxsjy/jieba
Commit Name: 99d0fb1a8a00c80c97271b2cc58d52c4fcff0032
Time: 2015-11-09
Author: abcdoyle888@gmail.com
File Name: jieba/__init__.py
Class Name: Tokenizer
Method Name: load_userdict