spinetoolbox.widgets.julia_repl_widget
¶
Class for a custom SpineConsoleWidget to use as julia REPL.
author: |
|
---|---|
date: | 22.5.2018 |
Module Contents¶
-
class
spinetoolbox.widgets.julia_repl_widget.
CustomQtKernelManager
[source]¶ Bases:
qtconsole.manager.QtKernelManager
A QtKernelManager with a custom restarter, and a means to override the –project argument.
-
class
spinetoolbox.widgets.julia_repl_widget.
JuliaREPLWidget
(toolbox)[source]¶ Bases:
spinetoolbox.widgets.spine_console_widget.SpineConsoleWidget
Class for a custom SpineConsoleWidget.
Parameters: toolbox (ToolboxUI) – QMainWindow instance -
julia_kernel_name
(self)[source]¶ Returns the name of the julia kernel specification according to the julia executable selected in settings. Returns None if julia version cannot be determined.
Returns: str, NoneType
-
_do_start_jupyter_kernel
(self, kernel_name=None)[source]¶ Starts a Jupyter kernel with the specified name.
Parameters: kernel_name (str, optional) –
-
handle_repl_failed_to_start
(self)[source]¶ Tries using IJulia.
Returns: True, False, or None if unable to determine. Return type: (bool, NoneType)
-
restart_jupyter_kernel
(self)[source]¶ Restarts the julia jupyter kernel if it’s already started. Starts a new kernel if none started or if the julia version has changed in Settings.
-
_handle_kernel_restarted
(self, died=True)[source]¶ Called when the kernel is restarted, i.e., when time to dead has elapsed.
-
_handle_kernel_left_dead
(self)[source]¶ Called when the kernel is finally declared dead, i.e., the restart limit has been reached.
-
handle_ijulia_installation_finished
(self, ret)[source]¶ Runs when IJulia installation process finishes
-
handle_ijulia_process_finished
(self, ret, process)[source]¶ Checks whether or not the IJulia process finished successfully.
Reimplemented to add an action for (re)start REPL action.
-