def extract(self):
if not self.extractable:<EOL><INDENT>return self, None<EOL><DEDENT>extractable = self.common_fams - self.extracted_fams<EOL>fam = sorted(extractable)[<NUM_LIT:0>]<EOL>last_range = None<EOL>ranges = set()<EOL>for variant in self.iter_variants():<EOL><INDENT>req = variant.get(fam)<EOL>if req.range != last_range:  <EOL><INDENT>ranges.add(req.range)<EOL>last_range = req.range<EOL><DEDENT><DEDENT>slice_ = copy.copy(self)<EOL>slice_.extracted_fams = self.extracted_fams | set([fam])<EOL>ranges = list(ranges)<EOL>range_ = ranges[<NUM_LIT:0>].union(ranges[<NUM_LIT:1>:])<EOL>common_req = Requirement.construct(fam, range_)<EOL>return slice_, common_req<EOL>
Extract a common dependency.

        Note that conflict dependencies are never extracted, they are always
        resolved via reduction.