ipython / ipython/ipykernel

Cannot restart and run all cells in notebooks with %gui qt magic

Đang mở
#559 1 bình luận 3 reaction 0 người được giao Xem trên GitHub
Ngôn ngữ chính
Python
Star
734
Fork
412
Merge trung bình
1 ngày 5 giờ
Pull request đã merge (30 ngày)
8

Mô tả

# Description

*Note: I originally submitted this issue in another repository (https://github.com/jupyter/jupyter_core/issues/207), who have suggested that here might be the right place instead. Please let me know if this isn't the right home for it.*

When I try to "Restart and Run All" cells with a notebook containing a `%gui qt` magic, the cells don't execute properly but hang intead.

Related (cc @jni): https://github.com/jupyter/nbclient/issues/97

# How to reproduce
You can reproduce it using [this example gist](https://gist.github.com/GenevieveBuckley/6ad4874a789949e9039becf783716bf4), and clicking "Restart & Run All".

Here's the version numbers of the most relevant packages in my environment:
```
ipykernel 5.3.4 pypi_0 pypi
ipython 7.19.0 pypi_0 pypi
ipython-genutils 0.2.0 pypi_0 pypi
jupyter 1.0.0 pypi_0 pypi
jupyter-book 0.8.3 pypi_0 pypi
jupyter-cache 0.4.1 pypi_0 pypi
jupyter-client 6.1.7 pypi_0 pypi
jupyter-console 6.2.0 pypi_0 pypi
jupyter-core 4.6.3 pypi_0 pypi
jupyter-sphinx 0.3.2 pypi_0 pypi
jupyterlab-pygments 0.1.2 pypi_0 pypi
matplotlib 3.3.2 pypi_0 pypi
nbclient 0.5.0 pypi_0 pypi
nbconvert 5.6.1 pypi_0 pypi
nbformat 5.0.7 pypi_0 pypi
numpy 1.19.2 pypi_0 pypi
pyqt5 5.14.2 pypi_0 pypi
pyqt5-sip 12.8.1 pypi_0 pypi
```

## What happened
The last cell hangs, and never produces the matplotlib graph. Here's a screenshot:

jupyter-notebook-restatrt-and-run-all

## What I expected to happen instead
I expected the notebook output to be the same as when I individually run each notebook cell in order.

jupyter-notebook-manual-run-all-cells

Hướng dẫn đóng góp

Mở hướng dẫn đóng góp

Đánh giá

Issue này chưa được đánh giá.

Nhận issue mới trong hộp thư của bạn

Bản tóm tắt ngắn những issue GitHub phù hợp với người mới.