rustworkx.PyGraph.add_node¶ PyGraph.add_node(obj, /)¶ Add a new node to the graph. Parameters: obj – The python object to attach to the node Returns: The index of the newly created node Return type: int