66c44551f903a45b9a2b870c3f7b98390535c36d,ilastik/__init__.py,,convertVersion,#Any#,68

Before Change


def convertVersion(vstring):
    if not isinstance(vstring, str):
        raise Exception("tried to convert non-string version: {}".format(vstring))
    return tuple(int(i) for i in vstring.split("."))


def isVersionCompatible(version):

After Change


    //  is simply converted to the integer 5 for compatibility purposes.
    int_tuple = ()
    for i in vstring.split("."):
        m = re.search("(\d+)", i)
        assert bool(m), "Don"t understand version component: {}".format( i )
        next_int = int(m.groups()[0])
        int_tuple = int_tuple + (next_int,)
    return int_tuple
Italian Trulli
In pattern: SUPERPATTERN

Frequency: 3

Non-data size: 3

Instances


Project Name: ilastik/ilastik
Commit Name: 66c44551f903a45b9a2b870c3f7b98390535c36d
Time: 2014-04-15
Author: bergs@janelia.hhmi.org
File Name: ilastik/__init__.py
Class Name:
Method Name: convertVersion


Project Name: GoogleCloudPlatform/PerfKitBenchmarker
Commit Name: 8dc40efdcfaa38fb133989ee7b57c75985753215
Time: 2020-10-15
Author: dphanekham@smu.edu
File Name: perfkitbenchmarker/linux_benchmarks/iperf_benchmark.py
Class Name:
Method Name: _RunIperf


Project Name: eth-cscs/reframe
Commit Name: 415b4241b76c6e24e43bca04be56a1e7b0439752
Time: 2019-01-29
Author: samuel.omlin@cscs.ch
File Name: reframe/core/schedulers/slurm.py
Class Name: SqueueJob
Method Name: _update_state