bokeh / jupyter_bokeh

An extension for rendering Bokeh content in JupyterLab notebooks
BSD 3-Clause "New" or "Revised" License
253 stars 48 forks source link

Tooltips not puplating #60

Closed mauermbq closed 5 years ago

mauermbq commented 5 years ago

referring to #55 it's still not working in my environment:

Name Version Build Channel

bokeh 1.0.0 py36_0
jupyterlab 0.35.2 py36_0
jupyterlab_server 0.2.0 py36_0

when I reinstall labextension by jupyter labextension install jupyterlab_bokeh jupyterlab_bokeh-0.6.3.tgz Node v8.12.0 I saw som warnings: warning css-loader > cssnano > autoprefixer > browserslist@1.7.7: Browserslist 2 could fail on reading Browserslist >3.0 config used in other tools. warning css-loader > cssnano > postcss-merge-rules > browserslist@1.7.7: Browserslist 2 could fail on reading Browserslist >3.0 config used in other tools. warning css-loader > cssnano > postcss-merge-rules > caniuse-api > browserslist@1.7.7: Browserslist 2 could fail on reading Browserslist >3.0 config used in other tools. [3/5] Fetching packages... info fsevents@1.2.4: The platform "linux" is incompatible with this module. info "fsevents@1.2.4" is an optional dependency and failed compatibility check. Excluding it from installation. [4/5] Linking dependencies... warning "@jupyterlab/vdom-extension > @nteract/transform-vdom@1.1.1" has incorrect peer dependency "react@^15.6.1". [5/5] Building fresh packages... success Saved lockfile. warning Your current version of Yarn is out of date. The latest version is "1.10.1", while you're on "1.9.4". Done in 58.74s.

canavandl commented 5 years ago

Those warnings are normal and it appears that you've correctly installed the jupyterlab_bokeh=0.6.3 extension onto jupyterlab=0.35.2 and are using bokeh=1.0.0.

What browser and OS are you using? Are you able to open the brower's developer console and see if there's any error output while you are hovering and the tooltips should appear?

mauermbq commented 5 years ago

I use actual chrome. Jupyterlab runs in a docker container, FROM clearlinux:base and miniconda from https://repo.continuum.io/miniconda/Miniconda3-latest-Linux-x86_64.sh

When loading the notebook, there is one warning regarding cors:

Access to Font at 'about:blank' from origin 'http://localhost:8899' has been blocked by CORS policy: Invalid response. Origin 'http://localhost:8899' is therefore not allowed access.

When I execute the cell containing graphic with tooltip output - no error in the dev console of chrome, fcomplete otput see below:

Bokeh: BokehJS not loaded, scheduling load and callback at Sat Oct 27 2018 21:14:13 GMT+0200 (Mitteleuropäische Sommerzeit)
Bokeh: injecting script tag for BokehJS library:  https://cdn.pydata.org/bokeh/release/bokeh-1.0.0.min.js
VM845:211 Bokeh: injecting script tag for BokehJS library:  https://cdn.pydata.org/bokeh/release/bokeh-widgets-1.0.0.min.js
VM845:211 Bokeh: injecting script tag for BokehJS library:  https://cdn.pydata.org/bokeh/release/bokeh-tables-1.0.0.min.js
VM845:211 Bokeh: injecting script tag for BokehJS library:  https://cdn.pydata.org/bokeh/release/bokeh-gl-1.0.0.min.js
VM841 bokeh-1.0.0.min.js:31 [bokeh] document idle at 39 ms
VM845:204 Bokeh: all BokehJS libraries loaded
VM845:264 Bokeh: BokehJS plotting callback run at Sat Oct 27 2018 21:14:14 GMT+0200 (Mitteleuropäische Sommerzeit)
bokeh-1.0.0.min.js:31 [bokeh] setting log level to: 'info'
VM845:231 Bokeh: injecting CSS: https://cdn.pydata.org/bokeh/release/bokeh-1.0.0.min.css
VM845:233 Bokeh: injecting CSS: https://cdn.pydata.org/bokeh/release/bokeh-widgets-1.0.0.min.css
VM845:235 Bokeh: injecting CSS: https://cdn.pydata.org/bokeh/release/bokeh-tables-1.0.0.min.css
VM845:181 Bokeh: all callbacks have finished
bryevdv commented 5 years ago

This is working for me with Bokeh 1.2 and extension 1.0.0next, so closing. I will note the value text is black, so if you are using a "dark" theme or something, that might explain things. I think for now you would have to target CSS to change bokeh built-in text props, but could use a custom tooltip to set whatever CSS/HTML you need.