Make ipython check work for python 3