obspy-runtests fails

I just tried to follow an example to download IRIS Instaseis synthetics:

My obspy was failing when it got to the cat.plot() line, saying that basemap
and cartopy weren’t installed. I tried installing them and then got other errors.

So, I started over. I followed this link to do a clean obspy install inside a new conda env:

Here are the steps I took (mac osx 10.10.5):

conda create -n obspy python=2.7
source activate obspy
conda install obspy
conda update obspy
conda list basemap // not present so I installed it - might want to indicate on the install page that basemap + cartopy must be installed separately
conda install basemap
conda install cartopy

Now the Instaseis example works, however, it spits out one deprecation warning:

/usr/local/anaconda/envs/obspy/lib/python2.7/site-packages/mpl_toolkits/basemap/init.py:1711: MatplotlibDeprecationWarning: The axesPatch function was deprecated in version 2.1. Use Axes.patch instead.
if limb is not ax.axesPatch:

And when I run obspy-runtests, I get tons of deprecation warnings + fails.
It’s a little overwhelming - where to start ??

In at least some cases, the fail seems to be a failure of the test (?), e.g.,:

Hi Mike,

many of these errors are due to numpy 1.14 changing the default print
output of array objects. This is already fixed in current developer
versions, so these (false positive) doctest fails won't show on future
release versions of obspy. (but there is no way to change what the
current obspy 1.1.0 test runner will show locally)

You could (temporarily) manually go back to numpy 1.13, then these false
test fails should not show up anymore.

That matplotlib warning showing up in basemap is out of our hands, but
I'll suppress it in future obspy versions. It's already fixed in basemap
(see https://github.com/matplotlib/basemap/issues/382) but this will
only go into effect once a new basemap version is released.

I've also added a note in the Installation wiki about installing basemap.


details see

Hi Mike,

these all seem to be from changes in new numpy and matplotlib versions. Both packages changed their string representations in some cases which we use for testing with their latest version amid some other changes.

We already fixes these in the master or some branch and they will fold into the next ObsPy release which will be out before too long.

From a quick glance at your log file none of these are true errors. It might help to revert to matplotlib 2.1 for the time being, e.g.

$ conda install matplotlib==2.1.2

Then you should be able to safely use ObsPy. Please note that you can also just report the test results by either running obspy-runtests -r or just agreeing at the end to report the results. They will then show up at tests.obspy.org which makes it easier for us to analyse the failures.