File tree Expand file tree Collapse file tree 2 files changed +11
-2
lines changed
Expand file tree Collapse file tree 2 files changed +11
-2
lines changed Original file line number Diff line number Diff line change 1+ ---
2+ fixes :
3+ - |
4+ Fixed a bug introduced in version 0.15 where the edge colors specified as
5+ a list in calls to :func:`~rustworkx.visualization.mpl_draw` were not
6+ having their order respected. Instead, the order of the colors was
7+ being shuffled. This has been restored and now the behavior should
8+ match that of 0.14.
Original file line number Diff line number Diff line change @@ -636,9 +636,10 @@ def draw_edges(
636636 edge_color = "k"
637637
638638 # set edge positions
639- edge_pos = set ()
639+ edge_pos_keys = dict ()
640640 for e in edge_list :
641- edge_pos .add ((tuple (pos [e [0 ]]), tuple (pos [e [1 ]])))
641+ edge_pos_keys [(tuple (pos [e [0 ]]), tuple (pos [e [1 ]]))] = None
642+ edge_pos = edge_pos_keys .keys ()
642643
643644 # Check if edge_color is an array of floats and map to edge_cmap.
644645 # This is the only case handled differently from matplotlib
You can’t perform that action at this time.
0 commit comments