Open dan-coates opened 5 years ago
Just ran into the same error:
[W 04:27:51.108 NotebookApp] Error loading server extension jupyter_spark
Traceback (most recent call last):
File "/opt/anaconda3/lib/python3.7/site-packages/notebook/notebookapp.py", line 1575, in init_server_extensions
func(self)
File "/opt/anaconda3/lib/python3.7/site-packages/jupyter_spark/__init__.py", line 30, in load_jupyter_server_extension
from .handlers import SparkHandler
File "/opt/anaconda3/lib/python3.7/site-packages/jupyter_spark/handlers.py", line 8, in <module>
class SparkHandler(IPythonHandler):
File "/opt/anaconda3/lib/python3.7/site-packages/jupyter_spark/handlers.py", line 13, in SparkHandler
@tornado.web.asynchronous
AttributeError: module 'tornado.web' has no attribute 'asynchronous'
$ pip freeze | egrep "tornado|jupyter|spark"
jupyter==1.0.0
jupyter-client==5.2.4
jupyter-console==6.0.0
jupyter-core==4.4.0
jupyter-spark==0.4.0
jupyterlab==0.35.4
jupyterlab-server==0.2.0
tornado==6.0.2
I'm having the same error, and I have the following related packages installed:
$ pip freeze | egrep "tornado|jupyter|spark|nbconvert"
findspark==1.3.0
handyspark==0.2.2a1
jupyter==1.0.0
jupyter-client==5.3.3
jupyter-console==6.0.0
jupyter-contrib-core==0.3.3
jupyter-contrib-nbextensions==0.4.0
jupyter-core==4.5.0
jupyter-highlight-selected-word==0.2.0
jupyter-latex-envs==1.4.6
jupyter-nbextensions-configurator==0.4.0
jupyter-spark==0.4.0
jupyterhub==1.0.0
jupyterlab==1.1.3
jupyterlab-server==1.0.6
jupyterthemes==0.20.0
nbconvert==5.6.1
pyspark==2.4.4
spark-stratifier==0.1.5
tornado==6.0.3
I have a fix for this here: https://github.com/mdboom/jupyter-spark/pull/1/files#diff-4573d7094611852f6d7f7323f9395dc3L2-L25
For anybody else trying to just work around the issue until it is fixed, downgrading tornado should do the trick:
pip uninstall tornado nbconvert jupyter-spark
pip install tornado==5.1.1
pip install nbconvert==5.1.0
pip install jupyter-spark
Hi guys ...
I was getting the same error today, was my first time using this:
File "/opt/anaconda3/lib/python3.7/site-packages/jupyter_spark/handlers.py", line 13, in SparkHandler
@tornado.web.asynchronous
Then I take 2 min to discover this URI https://www.tornadoweb.org/en/stable/releases/v3.1.0.html?highlight=tornado.web.asynchronous#tornado-web :
The tornado.web.asynchronous decorator is no longer necessary for methods that return a Future
Then I just commented that decoration, build the package and installed. The result was :
Jupyter-Spark enabled!
Tornado 6.0 appears to have removed the tornado.web.asynchronous method, which handlers.py relies on:
This has been noted in jupyter/notebook#4311 which may have a path to a fix.
pip freeze
of the environment this was run on under Python 3.6.8: