qgrid icon indicating copy to clipboard operation
qgrid copied to clipboard

qgrid.show_grid() only shows grid_options dictionary

Open clayms opened this issue 5 years ago • 17 comments

  • Operating System:
LSB Version:    :core-4.1-amd64:core-4.1-noarch
Distributor ID: RedHatEnterpriseServer
Description:    Red Hat Enterprise Linux Server release 7.3 (Maipo)
Release:        7.3
Codename:       Maipo
  • Python Version: Python 3.6.5 :: Anaconda, Inc.
  • How did you install Qgrid:
pip install qgrid
jupyter nbextension enable --py --sys-prefix qgrid
jupyter nbextension enable --py --sys-prefix widgetsnbextension

jupyter labextension install @jupyter-widgets/jupyterlab-manager
jupyter labextension install qgrid
  • Python packages: $ pip freeze or $ conda list (please include qgrid, notebook, and jupyterlab versions)
absl-py==0.4.0
alabaster==0.7.10
anaconda-client==1.6.14
anaconda-navigator==1.8.7
anaconda-project==0.8.2
asn1crypto==0.24.0
astor==0.7.1
astroid==1.6.3
astropy==3.0.2
attrs==17.4.0
Babel==2.5.3
backcall==0.1.0
backports.shutil-get-terminal-size==1.0.0
bcrypt==3.1.4
beautifulsoup4==4.6.0
bitarray==0.8.1
bkcharts==0.2
blaze==0.11.3
bleach==2.1.4
bokeh==0.12.16
boto==2.48.0
boto3==1.7.12
botocore==1.10.12
Bottleneck==1.2.1
bs4==0.0.1
cachetools==2.1.0
certifi==2018.4.16
cffi==1.11.5
chardet==3.0.4
click==6.7
clickclick==1.2.2
cloudpickle==0.5.3
clyent==1.2.2
colorama==0.3.9
conda==4.5.10
conda-build==3.10.5
conda-verify==2.0.0
connexion==1.1.9
contextlib2==0.5.5
cryptography==2.3
cycler==0.10.0
cymem==1.31.2
Cython==0.28.2
cytoolz==0.8.2
dask==0.17.5
datashape==0.5.4
datasketch==1.2.5
decorator==4.3.0
dill==0.2.7.1
distributed==1.21.8
distro==1.3.0
docutils==0.14
editdistance==0.4
eli5==0.7
en-core-web-lg==2.0.0
en-core-web-sm==2.0.0
entrypoints==0.2.3
et-xmlfile==1.0.1
extraction==2.6
extraction-api-client==2.15
extraction-api-server==2.15
fastcache==1.0.2
filelock==3.0.4
Flask==1.0.2
Flask-Cors==3.0.4
fonduer==0.2.3
future==0.16.0
gapic-google-cloud-datastore-v1==0.15.3
gapic-google-cloud-error-reporting-v1beta1==0.15.3
gapic-google-cloud-logging-v2==0.91.3
gast==0.2.0
gevent==1.3.0
glob2==0.6
gmpy2==2.0.8
google==2.0.1
google-api-core==0.1.4
google-auth==1.4.1
google-cloud==0.32.0
google-cloud-bigquery==0.28.0
google-cloud-bigquery-datatransfer==0.1.1
google-cloud-bigtable==0.28.1
google-cloud-container==0.1.1
google-cloud-core==0.28.1
google-cloud-datastore==1.4.0
google-cloud-dns==0.28.0
google-cloud-error-reporting==0.28.0
google-cloud-firestore==0.28.0
google-cloud-language==1.0.2
google-cloud-logging==1.4.0
google-cloud-monitoring==0.28.1
google-cloud-pubsub==0.30.1
google-cloud-resource-manager==0.28.1
google-cloud-runtimeconfig==0.28.1
google-cloud-spanner==0.29.0
google-cloud-speech==0.30.0
google-cloud-storage==1.6.0
google-cloud-trace==0.17.0
google-cloud-translate==1.3.1
google-cloud-videointelligence==1.0.1
google-cloud-vision==0.29.0
google-gax==0.15.16
google-resumable-media==0.3.1
googleapis-common-protos==1.5.3
googletrans==2.2.0
graphviz==0.8.3
greenlet==0.4.13
grpc-google-iam-v1==0.11.4
grpcio==1.11.0
h5py==2.7.1
heapdict==1.0.0
html5lib==1.0.1
httplib2==0.11.3
idna==2.6
imageio==2.3.0
imagesize==1.0.0
inflection==0.3.1
ipykernel==4.8.2
ipython==6.5.0
ipython-genutils==0.2.0
ipywidgets==7.2.1
isort==4.3.4
itsdangerous==0.24
jdcal==1.4
jedi==0.12.1
Jinja2==2.10
jmespath==0.9.3
jsonschema==2.6.0
jupyter==1.0.0
jupyter-client==5.2.3
jupyter-console==5.2.0
jupyter-core==4.4.0
jupyterlab==0.33.12
jupyterlab-launcher==0.13.1
Keras==2.0.8
kiwisolver==1.0.1
lazy-object-proxy==1.3.1
llvmlite==0.24.0
locket==0.2.0
lxml==3.6.4
Markdown==2.6.11
MarkupSafe==1.0
matplotlib==2.2.2
mccabe==0.6.1
mistune==0.8.3
mkl-fft==1.0.0
mkl-random==1.0.1
more-itertools==4.1.0
mpmath==1.0.0
msgpack==0.5.6
msgpack-numpy==0.4.1
msgpack-python==0.5.6
multipledispatch==0.5.0
murmurhash==0.28.0
mysql-connector-python==8.0.5
mysqlclient==1.3.13
navigator-updater==0.2.1
nbconvert==5.3.1
nbformat==4.4.0
networkx==2.1
nltk==3.3
nose==1.3.7
notebook==5.6.0
numba==0.39.0
numbskull==0.1.1
numexpr==2.6.5
numpy==1.14.3
numpydoc==0.8.0
oauth2client==3.0.0
odo==0.5.1
olefile==0.45.1
openpyxl==2.5.4
packaging==17.1
pandas==0.22.0
pandocfilters==1.4.2
paramiko==2.4.1
parso==0.3.1
partd==0.3.8
path.py==11.0.1
pathlib==1.0.1
pathlib2==2.3.2
patsy==0.5.0
pdfminer.six==20170720
pdftotree==0.4.0
pep8==1.7.1
pexpect==4.6.0
pickleshare==0.7.4
Pillow==5.1.0
pkginfo==1.4.2
plac==0.9.6
pluggy==0.6.0
ply==3.8
preshed==1.0.0
prometheus-client==0.3.1
prompt-toolkit==1.0.15
proto-google-cloud-datastore-v1==0.90.4
proto-google-cloud-error-reporting-v1beta1==0.15.3
proto-google-cloud-logging-v2==0.91.3
protobuf==3.6.1
psutil==5.4.5
psycopg2-binary==2.7.5
ptyprocess==0.6.0
py==1.5.3
py4j==0.10.6
pyasn1==0.4.2
pyasn1-modules==0.2.1
pycodestyle==2.4.0
pycosat==0.6.3
pycparser==2.18
pycrypto==2.6.1
pycryptodome==3.6.1
pycurl==7.43.0.1
pyflakes==1.6.0
Pygments==2.2.0
pylint==1.8.4
PyMySQL==0.9.2
PyNaCl==1.2.1
pyodbc==4.0.23
pyOpenSSL==18.0.0
pyparsing==2.2.0
PyPDF2==1.26.0
pyrouge==0.1.3
PySocks==1.6.8
pyspark==2.3.0
pytest==3.5.1
pytest-arraydiff==0.2
pytest-astropy==0.3.0
pytest-doctestplus==0.1.3
pytest-openfiles==0.3.0
pytest-remotedata==0.2.1
pytextrank==1.1.0
python-dateutil==2.6.1
python-Levenshtein==0.12.0
pytz==2018.4
PyWavelets==0.5.2
PyYAML==3.12
pyzmq==17.1.2
qgrid==1.1.1
QtAwesome==0.4.4
qtconsole==4.3.1
QtPy==1.4.1
redis==2.10.6
regex==2017.4.5
requests==2.18.4
rfc3987==1.3.7
rg-citation-extractor==0.2.8
rope==0.10.7
rsa==3.4.2
ruamel-yaml==0.15.35
s3transfer==0.1.13
schedule==0.5.0
scikit-image==0.13.1
scikit-learn==0.18.1
scipy==0.19.1
seaborn==0.8.1
selectivesearch==0.4
semver==2.8.0
Send2Trash==1.5.0
simplegeneric==0.8.1
singledispatch==3.4.0.3
six==1.11.0
sklearn==0.0
snowballstemmer==1.2.1
sortedcollections==0.6.1
sortedcontainers==1.5.10
spacy==2.0.11
Sphinx==1.7.4
sphinxcontrib-websupport==1.0.1
sputnik==0.9.3
spyder==3.2.8
SQLAlchemy==1.2.7
statistics==1.0.3.5
statsmodels==0.9.0
swagger-spec-validator==2.1.0
sympy==1.1.1
tables==3.4.3
tabula-py==1.2.0
tabulate==0.8.2
tblib==1.3.2
tensorboard==1.10.0
tensorflow==1.10.0
termcolor==1.1.0
terminado==0.8.1
testpath==0.3.1
textblob==0.15.1
thinc==6.10.2
tinys3==0.1.12
toolz==0.9.0
tornado==5.1
tqdm==4.23.3
traitlets==4.3.2
treedlib==0.1.1
typing==3.6.4
ujson==1.35
unicodecsv==0.14.1
urllib3==1.22
Wand==0.4.4
wcwidth==0.1.7
webencodings==0.5.1
Werkzeug==0.14.1
widgetsnbextension==3.2.1
wkrg-citation-extractor==1.0
wrapt==1.10.11
xgboost==0.71
xlrd==1.1.0
XlsxWriter==1.0.5
xlwt==1.3.0
zict==0.1.3
  • Jupyter lab packages (if applicable): $ jupyter labextension list
JupyterLab v0.33.12
Known labextensions:
   app dir: /home/user1/.local/share/jupyter/lab
@jupyter-widgets/jupyterlab-manager
        @jupyter-widgets/jupyterlab-manager v0.37.0  enabled  OK
qgrid
        qgrid v1.1.1  enabled  OK

Description of Issue

  • What did you expect to happen?
    • see the qgrid at output in the jupyter notebook.
  • What happened instead?
    • I see the following output:
QgridWidget(grid_options={'fullWidthRows': True, 'syncColumnCellResize': True, 'forceFitColumns': True, 'defaultColumnWidth': 150, 'rowHeight': 28, 'enableColumnReorder': False, 'enableTextSelectionOnCells': True, 'editable': True, 'autoEdit': False, 'explicitInitialization': True, 'maxVisibleRows': 15, 'minVisibleRows': 8, 'sortable': True, 'filterable': True, 'highlightSelectedCell': False, 'highlightSelectedRow': True, 'boldIndex': True}, id='6150802c-5100-4d8d-bd3e-e03414aaaabb', precision=5, show_toolbar=True)

Reproduction Steps

import numpy as np 
import pandas as pd

np.random.seed(142536)
d = np.random.randint(10, size=(4,3))
i = list(range(d.shape[0]))
c = ['col'+ str(x) for x in list(range(d.shape[1]))]

df = pd.DataFrame(data=d, index=i, columns=c)

import qgrid 
qgrid.show_grid(df, show_toolbar=True)

clayms avatar Aug 29 '18 16:08 clayms

Interesting...haven't had time to look at this yet but I'm hoping to find some time to go through the backlog of qgrid issues in the next week or so.

TimShawver avatar Sep 05 '18 12:09 TimShawver

I have a similar issue here..

Looking forward for your help :pray:

RobinDavid avatar Oct 19 '18 13:10 RobinDavid

I also have a similar issue in some (not all, and I don't know why) notebooks.

tqa236 avatar May 28 '19 13:05 tqa236

I am also having this issue on JupyterLab notebook instance on GCP.

GoodToast avatar Jul 24 '19 19:07 GoodToast

I am having the same issue with a conda installation of jupyter-lab v1.2.1. Python 3.7.3,

apahl avatar Nov 03 '19 15:11 apahl

I have the same issues. I've tested it on 2 different OS (Linux and Windows). On Windows it is working correctly. I hope it helps.

jarach avatar Jan 21 '20 15:01 jarach

Problem fixed for me (see #261)! It works now in a conda environment with jupyterlab v=1.2.4 and qgrid v=1.2.0, but I think the fix is actually due to a jupyterlab pop-up window that appeared after creating my latest environment saying:

Build Recommended
JupyterLab build is suggested:
@jupyter-widgets/jupyterlab-manager needs to be included in build
jupyter-matplotlib needs to be included in build
qgrid needs to be included in build 

I clicked on the button "build" and then qgrid started working in this environment. I changed the version of jupyterlab and qgrid in my other environments, but there was no "Build recommended" pop-up and in these environments qgrid still doesn't work. Do you know how I can give in the terminal the command qgrid to be included in this environments? Connected to this, qgrid only works if I first activate the working environment (conda activate env_qgr2) and start from there jupyter lab (jupyter lab). If I start from base or from another environment jupyter lab and then I change in jupyterlab with the "switch kernel" button to the correct one qgrid still doesn't work

My package versions:

$ conda list | grep -iE "jupy|ipython|note|qgrid|matplo|ipy|js"
ipykernel                 5.1.3            py37h5ca1d4c_0    conda-forge
ipympl                    0.4.1                      py_0    conda-forge
ipython                   7.11.1           py37h5ca1d4c_0    conda-forge
ipython_genutils          0.2.0                      py_1    conda-forge
ipywidgets                7.5.1                      py_0    conda-forge
json5                     0.8.5                      py_0    conda-forge
jsonschema                3.2.0                    py37_0    conda-forge
jupyter_client            5.3.4                    py37_1    conda-forge
jupyter_core              4.6.1                    py37_0    conda-forge
jupyterlab                1.2.4                      py_0    conda-forge
jupyterlab_server         1.0.6                      py_0    conda-forge
matplotlib-base           3.1.2            py37h250f245_1    conda-forge
nodejs                    13.7.0               h10a4023_0    conda-forge
notebook                  6.0.3                    py37_0    conda-forge
qgrid                     1.2.0                    pypi_0    pypi

$ jupyter labextension list
JupyterLab v1.2.4
Known labextensions:
   app dir: /home/nestor/anaconda3/envs/env_qgr2/share/jupyter/lab
        @jupyter-widgets/jupyterlab-manager v1.1.0  enabled  OK
        jupyter-matplotlib v0.5.0  enabled  OK
        qgrid v1.1.1  enabled  OK*

   local extensions:
        qgrid: /home/nestor/qgrid.git/js

Nestak2 avatar Jan 27 '20 10:01 Nestak2

Hello, I have the same problem? How do I fix this?

Thanks!

andrea-bistacchi avatar Jan 27 '20 18:01 andrea-bistacchi

@bistek For me the problem was connected to "build", as I have written above. You can try and see if my installation steps on conda will fix it on your machine:

# the first 4 lines just create an environment and a kernel
conda create -n env_qgr3 python=3.7
source activate env_qgr3
conda install ipykernel
python -m ipykernel install --user --name env_qgr3 --display-name "env_qgr3"

conda config --add channels conda-forge
conda install jupyterlab=1.2.4
conda install pip
pip install -U qgrid
git clone https://github.com/quantopian/qgrid.git
conda install nodejs
jupyter labextension install qgrid.git/js
jupyter nbextension enable --py --sys-prefix widgetsnbextension

Afterwards when you start jupyterlab, if you get a pop-up saying "Build Recommended", click on build. This was it for me.

Nestak2 avatar Jan 27 '20 22:01 Nestak2

I'm having this exact same issue. Qgrid works fine in Jupyter notebook but not Jupyter lab.

Error:

QgridWidget(grid_options={'fullWidthRows': True, 'syncColumnCellResize': True, 'forceFitColumns': False, 'defa…

Jupyterlab version: 1.2.6

Qgrid version: 1.30 (installed via pip install qgrid --upgrade)

Pandas version: 1.03

ipywidgets version: 7.5.1

Installed and built qgrid2-labextension based on the readme instructions. This is currently the only extension installed:

JupyterLab v1.2.6 Known labextensions: app dir: /anaconda3/share/jupyter/lab qgrid2 v1.1.2 enabled OK

Uninstalled core extensions: @jupyter-widgets/jupyterlab-manager jupyterlab-chart-editor jupyterlab-plotly plotlywidget

Running on CentOS 7. Help would be greatly appreciated! I've exhausted every option in this thread, including downgrading Jupyter lab in a new Conda environment. Nothing has worked.

aparente-nurix avatar Apr 03 '20 09:04 aparente-nurix

Dear all, it really looks like the only option would be to upgrade QGRID. Having it locked in downgraded environments would make it useless, since all other interacting packages are being updated regularly.

andrea-bistacchi avatar Apr 03 '20 09:04 andrea-bistacchi

@TimShawver Have you had a chance to take a look at this yet? Seems like a lot of people are having the same issues.

aparente-nurix avatar Apr 03 '20 22:04 aparente-nurix

Same issue here

dzm1982 avatar Apr 09 '20 10:04 dzm1982

Same issue here using jupyter on vscode

vkeerthivikram avatar Apr 13 '20 21:04 vkeerthivikram

Same issue. Updated Jupyter Lab, broke this.

seth-noaa avatar Oct 30 '20 17:10 seth-noaa

Also having this issue on jupyter notebook 6.1.4 with qgrid 1.3.1

rjbergerud avatar Dec 07 '20 02:12 rjbergerud

Any fix on this issue?

NaserNikandish avatar Jan 17 '21 14:01 NaserNikandish