what is the ipython notebook “Terminals” menu option

后端 未结 4 1880
日久生厌
日久生厌 2020-12-29 04:40

I am running ipython notebook on my OSX machine and/or my ubuntu 14.04 machine. I am using ipython 3.0.0, and ipython (jupyter) notebooks.

When I start an ipython n

4条回答
  •  Happy的楠姐
    2020-12-29 05:22

    Here's the code in Lib/site-packages/IPython/html/notebookapp.py responsible for this item (located the file by searching the source for "Terminals" case-sensitively):

    def init_terminals(self):
        try:
            from .terminal import initialize
            initialize(self.web_app)
            self.web_app.settings['terminals_available'] = True
        except ImportError as e:
            log = self.log.debug if sys.platform == 'win32' else self.log.warn
            log("Terminals not available (error was %s)", e)
    

    As you can see, there should be a message in the console log specifying what went wrong (you may need to increase log verbosity with ipython notebook --log-level= to see it). In my case, it said:

    Terminals not available (error was No module named fcntl)

    The html.terminal module that is being imported appears to provide a web-based IPython interactive console.

提交回复
热议问题