5b2327e051d5243f80b9b9f39f6800bbc8749bed,setup.py,,read,#,41

Before Change


// Create long description from README.rst and doc/CHANGES.rst.
// PYPI page will contain complete PyInstaller changelog.
def read(filename):
    try:
        return unicode(codecs.open(filename, encoding="utf-8").read())
    except NameError:
        return open(filename, "r", encoding="utf-8").read()
long_description = u"\n\n".join([read("README.rst"),
                                 read("doc/_dummy-roles.txt"),
                                 read("doc/CHANGES.rst")])
if sys.version_info < (3,):

After Change


def read(filename):
    if is_py2:
        with codecs.open(filename, encoding="utf-8") as fp:
            return unicode(fp.read())
    else:
        with open(filename, "r", encoding="utf-8") as fp:
            return fp.read()
Italian Trulli
In pattern: SUPERPATTERN

Frequency: 3

Non-data size: 3

Instances


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: lingpy/lingpy
Commit Name: b46114a5b8076c38e765811bd6d55ed2930d9975
Time: 2013-11-14
Author: mattis.list@posteo.de
File Name: lingpy/convert/html.py
Class Name:
Method Name: alm2html


Project Name: openml/openml-python
Commit Name: 33c3a8101efe1cb66599831c03a6b960248a8718
Time: 2016-03-25
Author: feurerm@informatik.uni-freiburg.de
File Name: openml/datasets/functions.py
Class Name:
Method Name: _get_dataset_qualities