3f5e994767718a930681d75bd59154525b02cd18,src/python/twitter/pants/targets/python_binary.py,PythonBinary,__init__,#PythonBinary#Any#Any#Any#Any#Any#Any#Any#Any#Any#Any#Any#Any#Any#Any#,24

Before Change


          "Can only declare an entry_point if no source binary is specified.")
    if not isinstance(platforms, (list, tuple)) and not isinstance(platforms, Compatibility.string):
      raise TargetDefinitionException("platforms must be a list, tuple or string.")
    if not isinstance(interpreters, (list, tuple)):
      raise TargetDefinitionException("interpreters must be a list or tuple.")

    self._entry_point = entry_point

After Change


    self._platforms = tuple(maybe_list(platforms or []))

    if source and entry_point:
      entry_point_module = entry_point.split(":", 1)[0]
      source_entry_point = self._translate_to_entry_point(self.sources[0])
      if entry_point_module != source_entry_point:
        raise TargetDefinitionException(self,
            "Specified both source and entry_point but they do not agree: %s vs %s" % (
Italian Trulli
In pattern: SUPERPATTERN

Frequency: 3

Non-data size: 3

Instances


Project Name: pantsbuild/pants
Commit Name: 3f5e994767718a930681d75bd59154525b02cd18
Time: 2014-01-19
Author: benjyw@gmail.com
File Name: src/python/twitter/pants/targets/python_binary.py
Class Name: PythonBinary
Method Name: __init__


Project Name: OpenMined/PySyft
Commit Name: 38cc1a6200c7937abce00310e2fc377de7a32a6c
Time: 2020-08-14
Author: vova@promail.spb.ru
File Name: src/syft/lib/generic.py
Class Name: ObjectConstructor
Method Name: install_inside_library


Project Name: cornellius-gp/gpytorch
Commit Name: 8fe38e41ac6f96d6e61d1bed5a0a15e77c8ebf61
Time: 2018-03-08
Author: sgross@fb.com
File Name: gpytorch/utils/sparse.py
Class Name:
Method Name: make_sparse_from_indices_and_values