V2EX = way to explore
V2EX 是一个关于分享和探索的地方
现在注册
已注册用户请  登录
推荐学习书目
Learn Python the Hard Way
Python Sites
PyPI - Python Package Index
http://diveintopython.org/toc/index.html
Pocoo
值得关注的项目
PyPy
Celery
Jinja2
Read the Docs
gevent
pyenv
virtualenv
Stackless Python
Beautiful Soup
结巴中文分词
Green Unicorn
Sentry
Shovel
Pyflakes
pytest
Python 编程
pep8 Checker
Styles
PEP 8
Google Python Style Guide
Code Style from The Hitchhiker's Guide
XIVN1987
V2EX  ›  Python

ipython 报错“Shell is already running a gui event loop for tk.”

  •  
  •   XIVN1987 · 14 天前 · 456 次点击

    升级了一下 ipython 执行就报上述错误,,执行步骤如下:

    D:\Python38\vexe\Scripts>ipython --pylab=tk
    Python 3.8.10 (tags/v3.8.10:3d8993a, May  3 2021, 11:48:03) [MSC v.1928 64 bit (AMD64)]
    Type 'copyright', 'credits' or 'license' for more information
    IPython 8.12.3 -- An enhanced Interactive Python. Type '?' for help.
    Installed tk event loop hook.
    Shell is already running a gui event loop for tk. Call with no arguments to disable the current loop.
    
    In [1]: x = arange(0, 2*pi, pi/100)
    
    In [2]: plot(x, sin(x))
    Out[2]: [<matplotlib.lines.Line2D at 0x224b1e5ee20>]
    
    In [3]:
    

    执行 plot 后弹出 Figure 窗口,,但窗口无内容显示,,一直处于卡死状态,,关闭 Figure 窗口后 ipython 也终止执行

    求教这个问题有大侠遇到吗??怎么解决?

    1 条回复
    XIVN1987
        1
    XIVN1987  
    OP
       13 天前
    创建的 issue: https://github.com/ipython/ipython/issues/14461

    希望能解决吧,,
    关于   ·   帮助文档   ·   博客   ·   API   ·   FAQ   ·   实用小工具   ·   3752 人在线   最高记录 6679   ·     Select Language
    创意工作者们的社区
    World is powered by solitude
    VERSION: 3.9.8.5 · 23ms · UTC 05:17 · PVG 13:17 · LAX 22:17 · JFK 01:17
    Developed with CodeLauncher
    ♥ Do have faith in what you're doing.