384d9c3cf0e79c592f43c8fd23623f95fbee91ac,release.py,,update_core_jsonnet,#Any#Any#Any#,102

Before Change


        with open(tmpfpath, "w") as ftmp:
            for raw_line in f:
                output_line = raw_line
                for srch_str in ["seldonio/apife","seldonio/cluster-manager", "seldonio/engine"]:
                    if raw_line.find(srch_str + ":") > 0:
                        output_line = get_output_line(raw_line, srch_str)
                ftmp.write(output_line)
        if debug:
            print("created {tmpfpath}".format(**locals()))
    shutil.move(tmpfpath, fpath) // move created tmp file to original file

After Change


        with open(tmpfpath, "w") as ftmp:
            for raw_line in f:
                output_line = raw_line
                if output_line.startswith("// @optionalParam seldonVersion"):
                    output_line = "// @optionalParam seldonVersion string "+seldon_core_version+" Seldon version\n"
                ftmp.write(output_line)
        if debug:
            print("created {tmpfpath}".format(**locals()))
    shutil.move(tmpfpath, fpath) // move created tmp file to original file
Italian Trulli
In pattern: SUPERPATTERN

Frequency: 4

Non-data size: 7

Instances


Project Name: SeldonIO/seldon-core
Commit Name: 384d9c3cf0e79c592f43c8fd23623f95fbee91ac
Time: 2018-11-26
Author: cc@seldon.io
File Name: release.py
Class Name:
Method Name: update_core_jsonnet


Project Name: mynlp/ccg2lambda
Commit Name: 66a06524eba0b22d14204baeb2ca6d4c9db7d1d0
Time: 2017-05-12
Author: pascual@nii.ac.jp
File Name: scripts/semantic_types.py
Class Name:
Method Name: convert_coq_to_nltk_type


Project Name: tensorflow/datasets
Commit Name: 5a68c464caac68e4623f9a7b173bcf24aa719a5c
Time: 2019-12-06
Author: adarob@google.com
File Name: tensorflow_datasets/text/trivia_qa.py
Class Name: TriviaQA
Method Name: _generate_examples


Project Name: studioml/studio
Commit Name: f31b7ad689b1435e76744af4ff443607643a37fd
Time: 2017-12-28
Author: peter.zhokhov@sentient.ai
File Name: studio/experiment.py
Class Name:
Method Name: create_experiment