fb9224b3d579e0e38f1966350fbb303905096c78,src/python/pants/engine/build_files.py,,addresses_from_address_families,#Any#Any#Any#,235

Before Change


    return False

  if type(spec) in (DescendantAddresses, SiblingAddresses, AscendantAddresses):
    addresses = tuple(a
                      for af in address_families
                      for a in af.addressables.keys()
                      if not exclude_address(a))
  elif type(spec) is SingleAddress:
    // TODO Could assert len(address_families) == 1, as it should always be true in this case.
    addresses = tuple(a
                      for af in address_families

After Change


    addresses = tuple(a for a in all_included_addresses() if a.target_name == spec.name)
    if not addresses and len(address_families) == 1:
      _raise_did_you_mean(address_families[0], spec.name)
  elif type(spec) is AscendantAddresses:
    addresses = tuple(all_included_addresses())
  else:
    raise ValueError("Unrecognized Spec type: {}".format(spec))
Italian Trulli
In pattern: SUPERPATTERN

Frequency: 3

Non-data size: 4

Instances


Project Name: pantsbuild/pants
Commit Name: fb9224b3d579e0e38f1966350fbb303905096c78
Time: 2017-11-27
Author: stuhood@twitter.com
File Name: src/python/pants/engine/build_files.py
Class Name:
Method Name: addresses_from_address_families


Project Name: pgmpy/pgmpy
Commit Name: 73dcacffa7dee910a9478cd7d783d91ef84dc987
Time: 2013-09-21
Author: snigam3112@gmail.com
File Name: BayesianModel.py
Class Name: BayesianModel
Method Name: add_nodes


Project Name: keras-team/keras
Commit Name: f06c7e4dcd9d3044580dff155cdeb4978e622188
Time: 2018-08-28
Author: ybliang8@gmail.com
File Name: keras/backend/cntk_backend.py
Class Name:
Method Name: conv1d