Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

ImportError: cannot import name 'configure_inline_support_orig' from 'matplotlib_inline.backend_inline' #12941

Open
balopat opened this issue May 2, 2021 · 3 comments

Comments

@balopat
Copy link

balopat commented May 2, 2021

After upgrading to ipython 7.23 we see this error when running our notebooks with papermill:

Exception encountered at "In [13]":
---------------------------------------------------------------------------
ImportError                               Traceback (most recent call last)
/opt/hostedtoolcache/Python/3.7.10/x64/lib/python3.7/site-packages/ipykernel/pylab/backend_inline.py in configure_once(*args)
    167             def configure_once(*args):
    168                 activate_matplotlib(backend)
--> 169                 configure_inline_support(ip, backend)
    170                 ip.events.unregister('post_run_cell', configure_once)
    171             ip.events.register('post_run_cell', configure_once)

/opt/hostedtoolcache/Python/3.7.10/x64/lib/python3.7/site-packages/IPython/core/pylabtools.py in configure_inline_support(shell, backend)
    384     )
    385 
--> 386     from matplotlib_inline.backend_inline import configure_inline_support_orig
    387 
    388     configure_inline_support_orig(shell, backend)

ImportError: cannot import name 'configure_inline_support_orig' from 'matplotlib_inline.backend_inline' (/opt/hostedtoolcache/Python/3.7.10/x64/lib/python3.7/site-packages/matplotlib_inline/backend_inline.py)

Downgrading to 7.22 makes it go away.
I did not dig deeper than this, happy to provide more details if necessary.

Here's a list of all my deps on this env (output of pip freeze):

ansiwrap==0.8.4
apipkg==1.5
appdirs==1.4.4
appnope==0.1.2
argon2-cffi==20.1.0
async-generator==1.10
attrs==20.3.0
backcall==0.2.0
black==21.4b2
bleach==3.3.0
cachetools==4.2.2
certifi==2020.12.5
cffi==1.14.5
chardet==4.0.0
click==7.1.2
cycler==0.10.0
decorator==4.4.2
defusedxml==0.7.1
entrypoints==0.3
execnet==1.8.0
filelock==3.0.12
google-api-core==1.26.3
google-auth==1.30.0
googleapis-common-protos==1.53.0
grpcio==1.37.1
idna==2.10
iniconfig==1.1.1
ipykernel==5.3.4
ipython==7.23.0
ipython-genutils==0.2.0
jedi==0.18.0
Jinja2==2.11.3
jsonschema==3.2.0
jupyter-client==6.1.12
jupyter-core==4.7.1
jupyterlab-pygments==0.1.2
kiwisolver==1.3.1
MarkupSafe==1.1.1
matplotlib==3.4.1
matplotlib-inline==0.1.2
mistune==0.8.4
mpmath==1.2.1
mypy-extensions==0.4.3
nbclient==0.5.3
nbconvert==6.0.7
nbformat==5.1.3
nest-asyncio==1.5.1
networkx==2.5.1
notebook==6.2.0
numpy==1.20.2
packaging==20.9
pandas==1.2.4
pandocfilters==1.4.3
papermill==2.3.3
parso==0.8.2
pathspec==0.8.1
pexpect==4.8.0
pickleshare==0.7.5
Pillow==8.2.0
pluggy==0.13.1
prometheus-client==0.10.1
prompt-toolkit==3.0.18
protobuf==3.13.0
ptyprocess==0.7.0
py==1.10.0
pyasn1==0.4.8
pyasn1-modules==0.2.8
pycparser==2.20
Pygments==2.8.1
pyparsing==2.4.7
pyrsistent==0.17.3
pytest==6.2.3
pytest-forked==1.3.0
pytest-xdist==2.2.1
python-dateutil==2.8.1
pytz==2021.1
PyYAML==5.4.1
pyzmq==22.0.3
regex==2021.4.4
requests==2.25.1
rsa==4.7.2
scipy==1.6.3
seaborn==0.11.1
Send2Trash==1.5.0
six==1.15.0
sortedcontainers==2.3.0
sympy==1.8
tenacity==7.0.0
terminado==0.9.4
testpath==0.4.4
textwrap3==0.9.2
toml==0.10.2
tornado==6.1
tqdm==4.60.0
traitlets==5.0.5
typing-extensions==3.10.0.0
urllib3==1.26.4
wcwidth==0.2.5
webencodings==0.5.1

@balopat
Copy link
Author

balopat commented May 2, 2021

I think https://github.com/ipython/ipython/pull/12940/files might fix this.

@MichaelBroughton
Copy link

A downgrade to ipython==7.22.0 also worked for me, thx @balopat .

@clobraico22
Copy link

Providing another data point here.

Downgrading to ipython==7.22.0 also worked for me.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

4 participants