New submission from David Mc Dougall <dam1...@g.rit.edu>:
The documentation for graphlib encourages users to represent their graphs in a awkward format. Graphs are currently represented using dictionaries of nodes, for example: graph["end_node"] = ["start_node"] And this is unintuitive because you can't use the graph traverse edges in their forward direction. If you look up a node in the graph, you get all of the nodes that point to the key, as opposed to all of the nodes that the key points to. The solution is to rewrite the documentation such that all of the edge directions are reversed. The final topologically sorted list will be in the "opposite" direction as a consequence. This will cause no functional changes. ---------- assignee: docs@python components: Documentation messages: 408535 nosy: dam1784, docs@python priority: normal severity: normal status: open title: Graphlib documentation type: enhancement versions: Python 3.10, Python 3.11, Python 3.9 _______________________________________ Python tracker <rep...@bugs.python.org> <https://bugs.python.org/issue46071> _______________________________________ _______________________________________________ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com