b1f3c9e10e725fc1cbeae90220a8b61fb78657c3,python/ray/autoscaler/command_runner.py,,_with_environment_variables,#Any#Any#,73

Before Change



    as_strings = []
    for key, val in environment_variables.items():
        if isinstance(val, dict):
            val = dict_as_one_line_yaml(val)
        s = "export {}={};".format(key, quote(val))
        as_strings.append(s)
    all_vars = "".join(as_strings)
    return all_vars + cmd

After Change



    as_strings = []
    for key, val in environment_variables.items():
        val = json.dumps(val, separators=(",", ":"))
        s = "export {}={};".format(key, quote(val))
        as_strings.append(s)
    all_vars = "".join(as_strings)
    return all_vars + cmd
Italian Trulli
In pattern: SUPERPATTERN

Frequency: 3

Non-data size: 3

Instances


Project Name: ray-project/ray
Commit Name: b1f3c9e10e725fc1cbeae90220a8b61fb78657c3
Time: 2020-08-28
Author: itswu.alex@gmail.com
File Name: python/ray/autoscaler/command_runner.py
Class Name:
Method Name: _with_environment_variables


Project Name: tyarkoni/pliers
Commit Name: b9f0e3feb28a46b6ca7e4f533e4dfeb4b8fb14aa
Time: 2018-03-20
Author: delavega@utexas.edu
File Name: pliers/utils/updater.py
Class Name:
Method Name: hash_data


Project Name: vatlab/SoS
Commit Name: fedaa64b5cdcdc483ce072220e9538f658b66ad4
Time: 2017-02-14
Author: ben.bog@gmail.com
File Name: sos/target.py
Class Name: RuntimeInfo
Method Name: write