matplotlib / matplotlib/ipympl

ipympl crashes when panning/zooming

Đang mở
#531 0 bình luận 0 reaction 0 người được giao Xem trên GitHub

Chưa có ai nhận issue này.

Ngôn ngữ chính
Jupyter Notebook
Star
1.7k
Fork
234
Chỉ số merge pull request
Không có pull request nào được merge trong 30 ngày

Mô tả

## Describe the issue
After a plot gets displayed in a notebook, I select either the zoom or pan button, move the cursor over the plot, and drag it to execute the operation. The plot correctly responds for a little while, but soon the server crashes with this error:

```
[E 16:08:31.532 NotebookApp] Uncaught exception, closing connection.
Traceback (most recent call last):
File "/Users/busko/Projects/software/miniconda3/envs/astro/lib/python3.10/site-packages/tornado/iostream.py", line 702, in _handle_events
self._handle_write()
File "/Users/busko/Projects/software/miniconda3/envs/astro/lib/python3.10/site-packages/tornado/iostream.py", line 976, in _handle_write
self._write_buffer.advance(num_bytes)
File "/Users/busko/Projects/software/miniconda3/envs/astro/lib/python3.10/site-packages/tornado/iostream.py", line 182, in advance
assert 0 < size <= self._size
AssertionError
Exception in callback None()
handle:
Traceback (most recent call last):
File "/Users/busko/Projects/software/miniconda3/envs/astro/lib/python3.10/asyncio/events.py", line 80, in _run
self._context.run(self._callback, *self._args)
File "/Users/busko/Projects/software/miniconda3/envs/astro/lib/python3.10/site-packages/tornado/platform/asyncio.py", line 206, in _handle_events
handler_func(fileobj, events)
File "/Users/busko/Projects/software/miniconda3/envs/astro/lib/python3.10/site-packages/tornado/iostream.py", line 702, in _handle_events
self._handle_write()
File "/Users/busko/Projects/software/miniconda3/envs/astro/lib/python3.10/site-packages/tornado/iostream.py", line 976, in _handle_write
self._write_buffer.advance(num_bytes)
File "/Users/busko/Projects/software/miniconda3/envs/astro/lib/python3.10/site-packages/tornado/iostream.py", line 182, in advance
assert 0 < size <= self._size
AssertionError
[W 16:08:31.533 NotebookApp] zmq message arrived on closed channel
```

## Versions
I suppose I'm using the latest versions of everything (under Python 3.10.9), sinceI just installed everything from scratch on a new Mac M1 (which has the developer tools and rosetta).

```
bash-3.2$ python -c "import sys; print('\n',sys.version); import ipympl; print('ipympl version:', ipympl.__version__)" && jupyter --version && jupyter nbextension list && jupyter labextension list

3.10.9 (main, Jan 11 2023, 09:18:20) [Clang 14.0.6 ]
ipympl version: 0.9.3
Selected Jupyter core packages...
IPython : 8.14.0
ipykernel : 6.24.0
ipywidgets : 8.0.7
jupyter_client : 8.3.0
jupyter_core : 5.3.1
jupyter_server : 2.7.0
jupyterlab : not installed
nbclient : 0.8.0
nbconvert : 7.7.1
nbformat : 5.9.1
notebook : 6.5.4
qtconsole : 5.4.3
traitlets : 5.9.0
Known nbextensions:
config dir: /Users/busko/Projects/software/miniconda3/envs/astro/etc/jupyter/nbconfig
notebook section
jupyter-matplotlib/extension enabled
- Validating: OK
jupyter-js-widgets/extension enabled
- Validating: OK
usage: jupyter [-h] [--version] [--config-dir] [--data-dir] [--runtime-dir] [--paths] [--json] [--debug] [subcommand]

Jupyter: Interactive Computing

positional arguments:
subcommand the subcommand to launch

options:
-h, --help show this help message and exit
--version show the versions of core jupyter packages and exit
--config-dir show Jupyter config dir
--data-dir show Jupyter data dir
--runtime-dir show Jupyter runtime dir
--paths show all Jupyter paths. Add --json for machine-readable format.
--json output paths as machine-readable json
--debug output debug information about paths

Available subcommands: bundlerextension console dejavu events execute kernel kernelspec migrate nbclassic nbconvert nbextension
notebook qtconsole run server serverextension troubleshoot trust

Jupyter command `jupyter-labextension` not found.

```

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

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

Bắt đầu từ đâu

  1. Đọc hết issue, rồi đọc hướng dẫn đóng góp của dự án.
  2. Bình luận trên issue rằng bạn sẽ nhận — tránh hai người làm cùng một việc.
  3. Fork repository và làm thay đổi trên một nhánh.
  4. Mở pull request có tham chiếu số hiệu của issue.

Hướng nghiên cứu

Tái hiện crash trong một notebook bằng cách hiển thị một biểu đồ và kéo bằng điều khiển thu phóng hoặc xoay, sử dụng thiết lập Python 3.10.9 và ipympl 0.9.3 được báo cáo. Bắt đầu với assertion của Tornado và các phiên bản gói Jupyter được liệt kê; hoàn tất khi có thể tiếp tục xoay và thu phóng mà không làm server hoặc kết nối bị crash.

Do mô hình lập chỉ mục viết ra từ nội dung của issue.

Đánh giá

Công nghệ
jupyter, jupyter-notebook, matplotlib, python
Lĩnh vực
data-visualization
Loại issue
Lỗi
Độ khó
4/5
Thời gian dự kiến
3-5 ngày
Mức độ hoạt động
Đình trệ
Độ rõ ràng
Cần làm rõ
Mức phù hợp với người mới
35/100

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.