2

jupyter-notebook 在我升级到 macOS High Sierra 之前工作正常。任何人都知道如何解决“oscript:无法打开默认脚本组件”问题?搜索这个网站和谷歌没有得到任何答案。我在 Anaconda 4.3.24 上。谢谢。

$ jupyter notebook
[I 08:12:13.340 NotebookApp] The port 8888 is already in use, trying another port.
[I 08:12:13.360 NotebookApp] Serving notebooks from local directory: /Users/Greenhorn/Local/projects
[I 08:12:13.360 NotebookApp] 0 active kernels 
[I 08:12:13.360 NotebookApp] The Jupyter Notebook is running at: http://localhost:8889/?token=9d8bde3a675f28b3cbc4c87b7eb0c36788b4d28260d9ed39
[I 08:12:13.360 NotebookApp] Use Control-C to stop this server and shut down all kernels (twice to skip confirmation).
[C 08:12:13.361 NotebookApp] 

    Copy/paste this URL into your browser when you connect for the first time,
    to login with a token:
        http://localhost:8889/?token=9d8bde3a675f28b3cbc4c87b7eb0c36788b4d28260d9ed39
osascript: can't open default scripting component.
4

1 回答 1

3

osascript我在诊断 Emacs Applescript 集成问题时遇到了完全相同的问题(Emacs 将错误报告为do-applescript: OSA language not available,但进一步调试导致我发现osascriptcan't open default scripting component)。我最近还升级到了 High Sierra。

不幸的是,在线用户发现太多需要重新安装 OSX 的建议。

就我而言,重新启动解决了这个问题。

您可以通过运行 test 命令进行诊断:

osascript -e 'tell app "Finder" to display dialog "Hello, World!"'

重启后,应该会弹出一个“Hello, World!” 对话。

于 2017-10-09T11:42:37.637 回答