vscode-jupyter: Matplot lib Widget does not work

Issue Type: Bug

Jupyter noteobok widgets aren’t displayed and when trying to create, the cell runs indefinitely and I have to quit VSCode to get Jupyter to stop

Extension version: 2021.11.1313923388-dev VS Code version: Code - Insiders 1.62.0-insider (Universal) (cad4c193d85f0891204da41c0508de39e7aa38c6, 2021-10-14T05:15:07.179Z) OS version: Darwin arm64 20.4.0 Restricted Mode: No Remote OS version: Linux x64 5.4.0-81-generic

System Info
Item Value
CPUs Apple M1 (8 x 24)
GPU Status 2d_canvas: enabled
gpu_compositing: enabled
metal: disabled_off
multiple_raster_threads: enabled_on
oop_rasterization: enabled
opengl: enabled_on
rasterization: enabled
skia_renderer: disabled_off_ok
video_decode: enabled
webgl: enabled
webgl2: enabled
Load (avg) 4, 2, 2
Memory (System) 16.00GB (0.70GB free)
Process Argv –crash-reporter-id 5fb29690-0fca-46a0-aa90-19896736f2fe
Screen Reader no
VM 0%
Item Value
Remote SSH: ucddark
OS Linux x64 5.4.0-81-generic
CPUs Intel® Xeon® CPU E5-2640 v3 @ 2.60GHz (32 x 1872)
Memory (System) 125.80GB (39.51GB free)
VM 0%
A/B Experiments
vsliv695:30137379
vsins829:30139715
vsliv368cf:30146710
vsreu685:30147344
python383cf:30185419
pythonvspyt602:30291494
vspor879:30202332
vspor708:30202333
vspor363:30204092
pythonvspyt639:30291487
pythontb:30258533
pythonptprofiler:30281269
vshan820:30294714
pythondataviewer:30285072
pythonvsuse255:30319630
vscod805cf:30301675
pythonvspyt200:30323110
vsccppwt:30382699
pythonvssor306:30340298
bridge0708:30335490
pygetstartedt2:30353727
bridge0723:30353136
pythonrunftest32:30365365
pythonf5test824:30361779
javagetstartedt:30350119
pythonvspyt187:30365360
pydsgst2:30361790
vsqsis300:30381676
vsaa593cf:30376535

About this issue

  • Original URL
  • State: closed
  • Created 3 years ago
  • Comments: 19 (12 by maintainers)

Most upvoted comments

Small update: Appears to be fixed for me since updating the jupyter extension to version v2021.11.1001550889 and vscode to version 1.63.0

@DonJayamanne %matplotlib ipympl does not work as well and behaves the same way as %matplitlib widget. %matplotlib notebook does not work and does not show a graph. I think this is expected according to #1948 and #4056. One more note: %matplotlib widget used to work before. It was one of the more recent updates that broke it. Not sure which one though, as I did not use the jupyter plugin for a few weeks. Using %matplotlib notebook never worked before. I attached the output of python3 -m pip list pip_list.txt

@claudiaregio I’m unable to repro this issue at my end, I’m on a Mac as well, lets discuss later today.

Running this MWE in a notebook cell gives the error.

%matplotlib widget
import matplotlib.pyplot as plt
import numpy as np
fig, ax = plt.subplots()
ax.plot(np.random.rand(10), np.random.rand(10), '.')

I love using this extension. Thank you for your help with this.