-
Notifications
You must be signed in to change notification settings - Fork 3
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Incompatible with ipywidgets >=8 #9
Comments
Are you behind a proxy? I see a net error…
On Mon, Mar 20, 2023 at 7:39 AM Kostis Anagnostopoulos < ***@***.***> wrote:
I cannot run these instructions:
OK: git clone https://github.com/johnomernik/qgrid
OK: cd qgrid
OK: python setup.py install
NOPE: pip install qgrid2-1.1.3-py3-none-any.whlcd ..
The problem is that python setup.py install does not (and couldn't ever)
build any wheel package,
but creates a dist/qgrid-1.3.1-py3.10.egg "link" file.
If i try to build a wheel out of this repo:
python setup.py bdist_wheel
...i get a dist/qgrid-1.3.1-py2.py3-none-any.whl file, but not qgrid2-...
that is given in the instructions.
And if i install this wheel, the following notebook-cell fails to render a
grid:
import pandas as pdimport numpy as npimport qgrid
df=pd.DataFrame(np.random.rand(200, 30), columns=[str(i) for i in range(30)])qgrid.show_grid(df)
...rendering instead this error output:
[image: image]
<https://user-images.githubusercontent.com/501585/226341105-4c075941-2b14-48cc-b52b-b72a82645114.png>
...which when i click it, it reveals:
[Open Browser Console for more detailed log - Double click to close this message]Failed to load model class 'QgridModel' from module 'qgrid'
Error: No version of module qgrid is registered
at f.loadClass ***@***.***/jupyterlab-manager/static/134.40eaa5b8e976096d50b2.js?v=40eaa5b8e976096d50b2:1:74856)
at f.loadModelClass ***@***.***/jupyterlab-manager/static/150.b0e841b75317744a7595.js?v=b0e841b75317744a7595:1:10729)
at f._make_model ***@***.***/jupyterlab-manager/static/150.b0e841b75317744a7595.js?v=b0e841b75317744a7595:1:7517)
at f.new_model ***@***.***/jupyterlab-manager/static/150.b0e841b75317744a7595.js?v=b0e841b75317744a7595:1:5137)
at f.handle_comm_open ***@***.***/jupyterlab-manager/static/150.b0e841b75317744a7595.js?v=b0e841b75317744a7595:1:3894)
at _handleCommOpen ***@***.***/jupyterlab-manager/static/134.40eaa5b8e976096d50b2.js?v=40eaa5b8e976096d50b2:1:73393)
at b._handleCommOpen (http://localhost:8888/static/lab/jlab_core.3e11c5239452d671150c.js?v=3e11c5239452d671150c:2:1037311)
at async b._handleMessage (http://localhost:8888/static/lab/jlab_core.3e11c5239452d671150c.js?v=3e11c5239452d671150c:2:1039301)
...and the browser-console is this:
150.b0e841b75317744a7595.js?v=b0e841b75317744a7595:1 Failed to fetch ipywidgets through the "jupyter.widget.control" comm channel, fallback to fetching individual model state. Reason: Control comm was closed too early_loadFromKernel @ 150.b0e841b75317744a7595.js?v=b0e841b75317744a7595:13134.40eaa5b8e976096d50b2.js?v=40eaa5b8e976096d50b2:1 Error: widget model not found
at f.get_model (150.b0e841b75317744a7595.js?v=b0e841b75317744a7595:1:3461)
at w.renderModel (134.40eaa5b8e976096d50b2.js?v=40eaa5b8e976096d50b2:1:72019)renderModel @ 134.40eaa5b8e976096d50b2.js?v=40eaa5b8e976096d50b2:1150.b0e841b75317744a7595.js?v=b0e841b75317744a7595:1 Error: No version of module qgrid is registered
at f.loadClass (134.40eaa5b8e976096d50b2.js?v=40eaa5b8e976096d50b2:1:74856)
at f.loadModelClass (150.b0e841b75317744a7595.js?v=b0e841b75317744a7595:1:10729)
at f._make_model (150.b0e841b75317744a7595.js?v=b0e841b75317744a7595:1:7517)
at f.new_model (150.b0e841b75317744a7595.js?v=b0e841b75317744a7595:1:5137)
at f.handle_comm_open (150.b0e841b75317744a7595.js?v=b0e841b75317744a7595:1:3894)
at _handleCommOpen (134.40eaa5b8e976096d50b2.js?v=40eaa5b8e976096d50b2:1:73393)
at b._handleCommOpen (default.js:1095:19)
at async b._handleMessage (default.js:1262:43)loadModelClass @ 150.b0e841b75317744a7595.js?v=b0e841b75317744a7595:1
DevTools failed to load source map: Could not load content for chrome-extension://cfhdojbkjhnklbpkdaibdccddilifddb/browser-polyfill.js.map: System error: net::ERR_FILE_NOT_FOUND
DevTools failed to load source map: Could not load content for chrome-extension://pgjjikdiikihdfpoppgaidccahalehjh/webspeed.js.map: System error: net::ERR_BLOCKED_BY_CLIENT
What am i missing?
—
Reply to this email directly, view it on GitHub
<#9>, or unsubscribe
<https://github.com/notifications/unsubscribe-auth/AAOXGUOXLDFSB7H3AK7XUKLW5BFYFANCNFSM6AAAAAAWBA4XNI>
.
You are receiving this because you are subscribed to this thread.Message
ID: ***@***.***>
--
Sent from my iThing
|
Yes, i'm behind a proxy. Additionally, i discovered a big mistake, and apologies for the title of this issue, actually the steps run quite well I will list here what i used: python3.10 -m venv --prompt qgrid ../venv-qgrid
. ~/Work/venv-qgrid/bin/activate
pip install jupyterlab ipywidgets pandas
cd qgrid-dev
python setup.py install
pip install qgrid2-1.1.3-py3-none-any.whl
cd .. And then in the cells above i get exactly the same error as before: [Open Browser Console for more detailed log - Double click to close this message]
Failed to load model class 'QgridModel' from module 'qgrid'
Error: No version of module qgrid is registered
at f.loadClass (http://localhost:8888/lab/extensions/@jupyter-widgets/jupyterlab-manager/static/134.40eaa5b8e976096d50b2.js?v=40eaa5b8e976096d50b2:1:74856)
at f.loadModelClass (http://localhost:8888/lab/extensions/@jupyter-widgets/jupyterlab-manager/static/150.b0e841b75317744a7595.js?v=b0e841b75317744a7595:1:10729)
at f._make_model (http://localhost:8888/lab/extensions/@jupyter-widgets/jupyterlab-manager/static/150.b0e841b75317744a7595.js?v=b0e841b75317744a7595:1:7517)
at f.new_model (http://localhost:8888/lab/extensions/@jupyter-widgets/jupyterlab-manager/static/150.b0e841b75317744a7595.js?v=b0e841b75317744a7595:1:5137)
at f.handle_comm_open (http://localhost:8888/lab/extensions/@jupyter-widgets/jupyterlab-manager/static/150.b0e841b75317744a7595.js?v=b0e841b75317744a7595:1:3894)
at _handleCommOpen (http://localhost:8888/lab/extensions/@jupyter-widgets/jupyterlab-manager/static/134.40eaa5b8e976096d50b2.js?v=40eaa5b8e976096d50b2:1:73393)
at b._handleCommOpen (http://localhost:8888/static/lab/jlab_core.48a41b637653e18e773e.js?v=48a41b637653e18e773e:2:1039756)
at async b._handleMessage (http://localhost:8888/static/lab/jlab_core.48a41b637653e18e773e.js?v=48a41b637653e18e773e:2:1041746) |
For reference: $ pip list | grep -iE 'note|jupy|ipy|qgrid|nodejs'
ipykernel 6.22.0
ipython 8.11.0
ipython-genutils 0.2.0
ipywidgets 8.0.4
jupyter_client 8.1.0
jupyter_core 5.3.0
jupyter-events 0.6.3
jupyter_server 2.5.0
jupyter_server_fileid 0.8.0
jupyter_server_terminals 0.4.4
jupyter_server_ydoc 0.8.0
jupyter-ydoc 0.2.3
jupyterlab 3.6.2
jupyterlab-pygments 0.2.2
jupyterlab_server 2.20.0
jupyterlab-widgets 3.0.5
nodejs-bin 18.4.0a4
notebook 6.5.3
notebook_shim 0.2.2
qgrid 1.3.1
qgrid2 1.1.3
$ jupyter labextension list
JupyterLab v3.6.2
/home/ankostis/Work/venv-qgrid/share/jupyter/labextensions
jupyterlab_pygments v0.2.2 enabled OK (python, jupyterlab_pygments)
qgrid2 v1.1.3 enabled OK (python, qgrid2)
@jupyter-widgets/jupyterlab-manager v5.0.5 enabled OK (python, jupyterlab_widgets) |
I think i nailed it! First, i suggest to retrofit slightly the installation instructions to build a wheel out ofthe sources, I played with the versions of the various core jupyter packages and discovered that cd qgrid-dev
/usr/bin/python3.10 -m venv --prompt qgrid venv && source venv/bin/activate
pip install wheel
python setup.py bdist_wheel # build a wheel inside `dist/`
pip install pandas jupyterlab 'ipywidgets<8' dist/qgrid-1.3.1-py2.py3-none-any.whl qgrid2-1.1.3-py3-none-any.whl |
I will post a PR to fix the dependencies of this project. |
This is a challenge of afraid in general. I am not strong enough to rewrite
it completely within the new extension framework, but I love how it’s laid
out and how it makes advice data analysis easy. I’d love to have a complete
rewrite rather than the bandaid approach I’ve taken
On Tue, Mar 21, 2023 at 7:26 AM Kostis Anagnostopoulos < ***@***.***> wrote:
I think i nailed it!
First, i suggest to retrofit slightly the installation instructions to
build a *wheel* out ofthe sources,
and use it whenever it is needed (instead of installing from the sources,
which i more brittle eg if the git-repo is removed.
I played with the versions of the various core jupyter packages and
discovered that qgrid fails to work when ipywidgets is 8+. To reproduce,
these are my (linux0 commands:
cd qgrid-dev
/usr/bin/python3.10 -m venv --prompt qgrid venv && source venv/bin/activate
pip install wheel
python setup.py bdist_wheel # build a wheel inside `dist/`
pip install pandas jupyterlab 'ipywidgets<8' dist/qgrid-1.3.1-py2.py3-none-any.whl qgrid2-1.1.3-py3-none-any.whl
—
Reply to this email directly, view it on GitHub
<#9 (comment)>,
or unsubscribe
<https://github.com/notifications/unsubscribe-auth/AAOXGUOO46PQP7G5Q7DYNULW5GNBBANCNFSM6AAAAAAWBA4XNI>
.
You are receiving this because you commented.Message ID:
***@***.***>
--
Sent from my iThing
|
Sure, a rewrite is very welcomed. Till then a PR with just this dependency capped will save many wasted days from other unlucky programmers on the planet. |
btw, i notice that it is not a git-fork from the original repo, the history of commits has been clipped. |
Yes, because I am not a developer, just a guy who wanted to use qgrid on a
newer version of jupyter lab. I honestly have no idea how any of this
works and am actually away from my dev box for 2 weeks. Sorry if my
responses are delayed
On Tue, Mar 21, 2023 at 8:38 AM Kostis Anagnostopoulos < ***@***.***> wrote:
btw, i notice that it is not a git-fork from the original repo, the
history of commits has been clipped.
is that on purpose?
—
Reply to this email directly, view it on GitHub
<#9 (comment)>,
or unsubscribe
<https://github.com/notifications/unsubscribe-auth/AAOXGUKZONPFB4GZZHE2GRLW5GVO3ANCNFSM6AAAAAAWBA4XNI>
.
You are receiving this because you commented.Message ID:
***@***.***>
--
Sent from my iThing
|
No problem. I like tidy git histories, i can help you fix this, if you want btw, PR#10 served! |
No problem. I am not sure the best approach approach here as I won’t be
able to
Merge this for a while (sorry, just not at a place where I can do it)
I know that my hack to make it work is a bit off, I was trying to find a
way to build it it in such a way that didn’t require building on everyone’s
machine (ie not needing node.is). I wonder hat would be the best way to to
garner interest I this. I think the bones of qgrid are real good. I like
the ability to edit and pull the edited data frame off, I like resizing of
columns, etc . Just need to figure out how to simplify and get it future
proof
On Tue, Mar 21, 2023 at 8:46 AM Kostis Anagnostopoulos < ***@***.***> wrote:
No problem.
I like tidy git histories, i can help you fix this, if you want
btw, PR#10 served!
—
Reply to this email directly, view it on GitHub
<#9 (comment)>,
or unsubscribe
<https://github.com/notifications/unsubscribe-auth/AAOXGUNKK3QGI67ZKDM4JNDW5GWJVANCNFSM6AAAAAAWBA4XNI>
.
You are receiving this because you commented.Message ID:
***@***.***>
--
Sent from my iThing
|
Actually that's what makes this fork so handy! Future-proofing...needs automation to test the combinations of all major bumps for all main jupyterlab components...but this devops takes some considerable time. About merging...if i had some time, i would offer to help you maintain this project. |
Is the intention of this particular issue to fix the compatibility with |
The latter, accept the fact that it dosn't work with |
@ankostis did you look into what the incompatibility is? I might be interested to spend some time and try to fix it, at least in case it doesn't require huge amounts of work. |
No |
But maybe you can take some ideas from a respective conda package (if indeed it works). |
Highly recommend people check out https://github.com/zhihanyue/qgridnext |
I cannot run these instructions:
git clone https://github.com/johnomernik/qgrid
cd qgrid
python setup.py install
NOPEOK:pip install qgrid2-1.1.3-py3-none-any.whl
The problem is thatpython setup.py install
does not (and couldn't ever) build any wheel package,but creates a
dist/qgrid-1.3.1-py3.10.egg
"link" file.If i try to build a wheel out of this repo:
...i get a
dist/qgrid-1.3.1-py2.py3-none-any.whl
file, but notqgrid2-...
that is given in the instructions.And if i install this wheel, the following notebook-cell fails to render a grid:
...rendering instead this error output:
...which when i click it, it reveals:
...and the browser-console is this:
What am i missing?
The text was updated successfully, but these errors were encountered: