class_docstr: MultiDiGraph which assigns unique keys to every edge.
  
  Adds a dictionary edge_index which maps edge keys to (u, v, data) tuples.
  
  This is not a complete implementation. For Edmonds algorithm, we only use
  add_node and add_edge, so that is all that is implemented here. During
  additions, any specified keys are ignored---this means that you also
  cannot update edge attributes through add_node and add_edge.
  
  Why do we need this? Edmonds algorithm requires that we track edges, even
  as we change the head and tail of an edge, and even changing the weight
  of edges. We must reliably track edges across graph mutations.
docstr: Key is now required.
code: def add_edge(self, u_for_edge, v_for_edge, key_for_edge, **attr):
      """
      Key is now required.
  
      """
      u, v, key = u_for_edge, v_for_edge, key_for_edge
      if key in self.edge_index:
          uu, vv, _ = self.edge_index[key]
          if (u != uu) or (v != vv):
              raise Exception(f"Key {key!r} is already in use.")
  
      self._cls.add_edge(u, v, key, **attr)
      self.edge_index[key] = (u, v, self.succ[u][v][key])
  
imports: import string
  from dataclasses import dataclass, field
  from enum import Enum
  from operator import itemgetter
  from queue import PriorityQueue
  import networkx
  from networkx.utils import py_random_state
  from .recognition import is_arborescence, is_branching
label_desc: Use image node_id 4 for calling the MultiDiGraph_EdgeKey obj's underlying member method code with example usage: obj.add_edge(u_for_edge, v_for_edge, key_for_edge) without return types