Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Commit 17d9ada

Browse files
committed
FIX : order of operation is Poly3DCollection init
Make sure parent class is `__init__`'d before trying to use a function that requires _stale attribute.
1 parent 096d714 commit 17d9ada

File tree

1 file changed

+2
-3
lines changed

1 file changed

+2
-3
lines changed

lib/mpl_toolkits/mplot3d/art3d.py

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -484,10 +484,9 @@ def __init__(self, verts, *args, **kwargs):
484484
Note that this class does a bit of magic with the _facecolors
485485
and _edgecolors properties.
486486
'''
487-
488-
self.set_zsort(kwargs.pop('zsort', True))
489-
487+
zsort = kwargs.pop('zsort', True)
490488
PolyCollection.__init__(self, verts, *args, **kwargs)
489+
self.set_zsort(zsort)
491490

492491
_zsort_functions = {
493492
'average': np.average,

0 commit comments

Comments
 (0)