b72e0df77218fb3e8cb938fe344c3412ccb65bd4,sos/actions.py,,report,#Any#Any#Any#,574

Before Change


    // file lock to prevent race condition
    with fasteners.InterProcessLock("/tmp/report_lock"):
        if input is not None:
            if script is not None and script.strip():
                raise ValueError("Please specify only one of parameter script and input: script={}, input={}".format(script, input))
            if isinstance(input, str):
                env.logger.debug("Loading report from {}".format(input))
                with open(input) as ifile:
                    writer(ifile.read())

After Change


    // file lock to prevent race condition
    with fasteners.InterProcessLock("/tmp/report_lock"):
        if isinstance(script, str) and script.strip():
            writer(script.rstrip() + "\n\n")
        if input is not None:
            if isinstance(input, str):
                env.logger.debug("Loading report from {}".format(input))
Italian Trulli
In pattern: SUPERPATTERN

Frequency: 3

Non-data size: 3

Instances


Project Name: vatlab/SoS
Commit Name: b72e0df77218fb3e8cb938fe344c3412ccb65bd4
Time: 2016-12-16
Author: ben.bog@gmail.com
File Name: sos/actions.py
Class Name:
Method Name: report


Project Name: vatlab/SoS
Commit Name: 7cdb2074318a449647168fb087f2f2a775164863
Time: 2016-12-16
Author: ben.bog@gmail.com
File Name: sos/actions.py
Class Name:
Method Name: report


Project Name: mindsdb/mindsdb
Commit Name: 7283915223e65af525bc8334e7593bbcac9943cf
Time: 2020-06-26
Author: wzzhz13@gmail.com
File Name: distributions/windows/install.py
Class Name:
Method Name: