def get_ties(G):
<EOL>ties = []<EOL>dep_dict = {}<EOL>for node in G.nodes(data=True):<EOL><INDENT>if '<STR_LIT>' in node[<NUM_LIT:1>]:<EOL><INDENT>for item in node[<NUM_LIT:1>]['<STR_LIT>']:<EOL><INDENT>if item not in dep_dict:<EOL><INDENT>dep_dict[item] = []<EOL><DEDENT>dep_dict[item].append(node[<NUM_LIT:0>])<EOL><DEDENT><DEDENT><DEDENT>for item in dep_dict:<EOL><INDENT>if len(list(set(dep_dict[item]))) > <NUM_LIT:1>:<EOL><INDENT>ties.append(list(set(dep_dict[item])))<EOL><DEDENT><DEDENT>return ties<EOL>
If you specify a target that shares a dependency with another target,
both targets need to be updated. This is because running one will resolve
the sha mismatch and sake will think that the other one doesn't have to
run. This is called a "tie". This function will find such ties.