I am running Python 2.7 on a Windows 7 OS
Here is what I run:
>>> import matplotlib.pyplot as plt
Then I get this:
I got exactly the same error message. And it seams there are many many possible causes. In my case, I solved the issue by reinstalling six
pip uninstall six ; pip install six
I guess the previous installation was aborted before a complete termination. Or maybe a permission issue. Or something else ... now it's too late to investigate what was the real cause.