1e3f7071cf4095abfface461164703106563c459,src/python/pants/engine/exp/graph.py,,parse_address_family,#Any#Any#,30

Before Change


  Given the spec path for an Address, parses and returns its AddressFamily.
  // TODO: break up AddressMapper rather than using private APIs
  family = address_mapper._maybe_family(directory.path)
  if not family:
    raise ResolveError("No addresses registered in {}".format(directory))
  return family


class UnhydratedStruct(datatype("UnhydratedStruct", ["address", "struct", "dependencies"])):
  A product type that holds a Struct which has not yet been hydrated.

After Change



def parse_address_family(address_mapper, directory):
  Given a Directory, parses and returns its AddressFamily (which may be empty, but not None).
  return address_mapper.family(directory.path)


class UnhydratedStruct(datatype("UnhydratedStruct", ["address", "struct", "dependencies"])):
  A product type that holds a Struct which has not yet been hydrated.
Italian Trulli
In pattern: SUPERPATTERN

Frequency: 3

Non-data size: 7

Instances


Project Name: pantsbuild/pants
Commit Name: 1e3f7071cf4095abfface461164703106563c459
Time: 2016-02-22
Author: stuhood@gmail.com
File Name: src/python/pants/engine/exp/graph.py
Class Name:
Method Name: parse_address_family


Project Name: pantsbuild/pants
Commit Name: 1e3f7071cf4095abfface461164703106563c459
Time: 2016-02-22
Author: stuhood@gmail.com
File Name: src/python/pants/engine/exp/mapper.py
Class Name: AddressMapper
Method Name: family


Project Name: pantsbuild/pants
Commit Name: 1e3f7071cf4095abfface461164703106563c459
Time: 2016-02-22
Author: stuhood@gmail.com
File Name: src/python/pants/engine/exp/mapper.py
Class Name: AddressMapper
Method Name: resolve