Jupyter Scala Kernel Missing

时间:2015-09-21 22:42:52

标签: scala jupyter

我在OS X 10.10.5上运行。我正在尝试将Scala内核添加到我的Jupyter笔记本中。

$ jupyter --version
4.0.4

$ conda --version
conda 3.17.0

我从git下载了jupyter-scala,然后从源代码构建了Scala 2.11。

$ sbt cli/target

$ ls -l /Users/davidlaxer/jupyter-scala/cli/target/scala-2.11/

total 224

drwxr-xr-x 4 davidlaxer staff 136 Sep 21 12:39 classes
-rw-r--r-- 1 davidlaxer staff 114465 Sep 21 12:39 jupyter-scala-cli_2.11.6-0.2.0-SNAPSHOT.jar

$ sudo jupyter kernelspec install scala-2.11/

Password:

[InstallKernelSpec] Installed kernelspec in /usr/local/share/jupyter/kernels/

David-Laxers-MacBook-Pro:target davidlaxer$ jupyter kernelspec list

Available kernels:

ir
julia-0.3
matlab_kernel
python2

$ ls -l /usr/local/share/jupyter/kernels/
total 224
drwxr-xr-x  4 root  wheel     136 Sep 21 12:39 classes
-rw-r--r--  1 root  wheel  114465 Sep 21 12:39 jupyter-scala-cli_2.11.6-0.2.0-SNAPSHOT.jar

为什么我没有看到scala2.11内核?

没有Scala!

enter image description here

1 个答案:

答案 0 :(得分:3)

要从源代码安装jupyter-scala,您应该执行类似

的操作
sid

然后git clone https://github.com/alexarchambault/jupyter-scala.git cd jupyter-scala sbt cli/pack cli/target/pack/bin/jupyter-scala 应显示scala211。

对于Scala 2.10内核,请查看scala-2.10.x分支,并执行sbt ++ 2.10.5 cli / pack而不是sbt cli / pack。内核名称是scala210。请注意,要以这种方式同时拥有两个内核,您应该例如将repo克隆到两个不同的目录中。

-