- Add -doc patch to fix building the gallery of examples. - Add -is patch to reduce noise in sagemath. - Add upstream bug fix patches: -source-target, -union-find, -cb-iterable, -iterable, and -dict-iteration.
28 lines
1.1 KiB
Diff
28 lines
1.1 KiB
Diff
https://github.com/networkx/networkx/commit/d27930ce099d6f0edca8d5d91d5f3a8d9dc90c9d
|
|
|
|
Fix deprecation warning with Python 3.7 (#3487)
|
|
|
|
Replace collections.Iterable with collections.abc.Iterable to fix deprecation warning with Python 3.7:
|
|
"DeprecationWarning: Using or importing the ABCs from 'collections' instead of from 'collections.abc' is deprecated, and in 3.8 it will stop working"
|
|
|
|
--- networkx/drawing/nx_pylab.py.orig 2019-09-11 10:14:12.380878784 -0600
|
|
+++ networkx/drawing/nx_pylab.py 2019-09-11 10:14:26.196649773 -0600
|
|
@@ -373,7 +373,7 @@ def draw_networkx_nodes(G, pos,
|
|
draw_networkx_labels()
|
|
draw_networkx_edge_labels()
|
|
"""
|
|
- import collections
|
|
+ from collections.abc import Iterable
|
|
try:
|
|
import matplotlib.pyplot as plt
|
|
import numpy as np
|
|
@@ -399,7 +399,7 @@ def draw_networkx_nodes(G, pos,
|
|
except ValueError:
|
|
raise nx.NetworkXError('Bad value in node positions.')
|
|
|
|
- if isinstance(alpha, collections.Iterable):
|
|
+ if isinstance(alpha, Iterable):
|
|
node_color = apply_alpha(node_color, alpha, nodelist, cmap, vmin, vmax)
|
|
alpha = None
|
|
|