Hi all,
I don’t think the cached_method discussion is relevant here. What we do is save some plot defaults (coordinates of points, possibly others) into the data structure so that a matroid “knows” how it is best drawn, and so that subsequent calls to “plot” or “show” give the same drawing, even if the internal “active” basis has changed.
As for the error, it’s a bit strange. In line 7297, we call that method, apparently with argument pos_dict equal to “None”. But that code is inside an “if” statement prohibiting that! So what I’d do is add a bunch of
print “Line xxxx”, pos_dict
statements for debugging, so you know exactly what kind of data structure is passed on in each step.
Generally speaking, methods are a cleaner, safer way to do things than direct assignment. That way any changes in future versions of the object are less likely to introduce slumbering errors.
Hope this helps,
Stefan.