Skip to content

Transactional adds/removes #15

@ghost

Description

As a compromise between the status quo and #12, what about adding a transactional add/remove of nodes and edges?

For example, some code like this:

for node_ind in nodes_to_remove.iter() {
  tree.remove_node(*node_ind);
}
for edge_ind in edges_to_remove.iter() {
  tree.remove_edge(*edge_ind);
}

As I understand it, this code has somewhat random behavior since each run through the loop will cause the tree to change. However, if I could specify something like tree.transact(&nodes_to_remove, tree.remove_node), that would solve my own stability needs without needing the whole graph to be redone.

On the other hand, it's a very database thing to do.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions