0e1816da44c9769c9e1637b0c82660f010e0755a,setup.py,,read,#Any#,44

Before Change




def read(fname):
    return open(os.path.join(os.path.dirname(__file__), fname)).read()

def read_to_rst(fname):
    try:
        import pypandoc

After Change



def read(fname):
    try:
        with open(os.path.join(os.path.dirname(__file__), fname)) as f:
            return unicode(f.read())
    except NameError:
        //python 3
        with open(os.path.join(os.path.dirname(__file__), fname)) as f:
            return (f.read())
Italian Trulli
In pattern: SUPERPATTERN

Frequency: 3

Non-data size: 9

Instances


Project Name: SheffieldML/GPy
Commit Name: 0e1816da44c9769c9e1637b0c82660f010e0755a
Time: 2015-10-07
Author: ibinbei@gmail.com
File Name: setup.py
Class Name:
Method Name: read


Project Name: pyinstaller/pyinstaller
Commit Name: 5b2327e051d5243f80b9b9f39f6800bbc8749bed
Time: 2018-09-09
Author: contact@tiger-222.fr
File Name: setup.py
Class Name:
Method Name: read


Project Name: tensorlayer/tensorlayer
Commit Name: 6f539ad2324ddccc18b6ac39e4a2f4aeb12173a2
Time: 2018-04-17
Author: DEKHTIARJonathan@users.noreply.github.com
File Name: tests/test_yapf_format.py
Class Name:
Method Name: _read_utf_8_file