Kanaries / pygwalker

PyGWalker: Turn your pandas dataframe into an interactive UI for visual analysis
https://kanaries.net/pygwalker
Apache License 2.0
10.83k stars 549 forks source link

[BUG] pygwalker bug report - interactive panel doesn't show up #526

Closed PabloJMoreno closed 3 months ago

PabloJMoreno commented 3 months ago

Describe the bug A clear and concise description of what the bug is.


import pandas as pd
import pygwalker as pyg
df = pd.read_csv('data.csv')
chart = pyg.walk(df)```

After installing and invocking pygwalker, the interactive panel doesn't show up, showing the following error message: 

Open Browser Console for more detailed log - Double click to close this message]
Failed to load model class 'BoxModel' from module '@jupyter-widgets/controls'
Error: Module @jupyter-widgets/controls, version ^1.5.0 is not registered, however,         2.0.0 is
    at f.loadClass (http://localhost:8888/lab/extensions/@jupyter-widgets/jupyterlab-manager/static/134.fe2572ece3b7955c89bb.js?v=fe2572ece3b7955c89bb:1:75054)
    at f.loadModelClass (http://localhost:8888/lab/extensions/@jupyter-widgets/jupyterlab-manager/static/336.0a90bd910629a565bb7e.js?v=0a90bd910629a565bb7e:1:10728)
    at f._make_model (http://localhost:8888/lab/extensions/@jupyter-widgets/jupyterlab-manager/static/336.0a90bd910629a565bb7e.js?v=0a90bd910629a565bb7e:1:7516)
    at f.new_model (http://localhost:8888/lab/extensions/@jupyter-widgets/jupyterlab-manager/static/336.0a90bd910629a565bb7e.js?v=0a90bd910629a565bb7e:1:5136)
    at f.handle_comm_open (http://localhost:8888/lab/extensions/@jupyter-widgets/jupyterlab-manager/static/336.0a90bd910629a565bb7e.js?v=0a90bd910629a565bb7e:1:3893)
    at _handleCommOpen (http://localhost:8888/lab/extensions/@jupyter-widgets/jupyterlab-manager/static/134.fe2572ece3b7955c89bb.js?v=fe2572ece3b7955c89bb:1:73470)
    at v._handleCommOpen (http://localhost:8888/static/notebook/3676.bundle.js:1:30808)
    at async v._handleMessage (http://localhost:8888/static/notebook/3676.bundle.js:1:32702)

**To Reproduce**
Steps to reproduce the behavior:
1. Go to '...'
2. Click on '....'
3. Scroll down to '....'
4. See error

**Expected behavior**
A clear and concise description of what you expected to happen.
To open the interactive graphic interface

**Screenshots**
If applicable, add screenshots to help explain your problem.

**Versions**
- pygwalker version: latest
- python version: 3.9.19
- browser: edge latest
- jupyter: 1.0.0
- jupyterlab: 4.0.7
- jupyterlab-widgets: 1.1.7
- ipywidgets; 7.7.5

**Additional context**
Add any other context about the problem here.

Problem started when updated to latest Anaconda version
longxiaofei commented 3 months ago

Hi @PabloJMoreno ,This may be caused by ipywidgets dependency version.

try it:

pip install --upgrade ipywidgets

PabloJMoreno commented 3 months ago

Hello, I was researching a bit on this, and thsi is what I did to solve the issue:

pip install ipywidgets==8 pip install voila

this solves my problem and the interactive panel renders properly

Thank you teak for this awesome development Pablo