Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/OctoPrint/OctoPrint.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
path: root/docs
diff options
context:
space:
mode:
authorGina Häußge <gina@octoprint.org>2021-10-11 17:11:13 +0300
committerGina Häußge <gina@octoprint.org>2021-10-11 17:11:13 +0300
commit577c8020a1008ad9776b6e0b565ad02d87fd01fd (patch)
tree57089285be01e9e61e435a9f3bf847ffc666a0c0 /docs
parent3daddb239e99dcbf41a7c12bfdd2d2a547996f01 (diff)
parent1a13d5455908bf6e775711973ffa8c7bd5ef6699 (diff)
Merge branch 'maintenance' of github.com:OctoPrint/OctoPrint into maintenance
Diffstat (limited to 'docs')
-rw-r--r--docs/plugins/concepts.rst13
1 files changed, 13 insertions, 0 deletions
diff --git a/docs/plugins/concepts.rst b/docs/plugins/concepts.rst
index 5e1c624cf..1be34d43b 100644
--- a/docs/plugins/concepts.rst
+++ b/docs/plugins/concepts.rst
@@ -35,9 +35,22 @@ any :ref:`settings overlays <sec-plugins-controlproperties-plugin_settings_overl
On disabling a plugin, its hook handlers, helpers, mixin implementations and settings overlays will be de-registered again.
+When a plugin gets enabled, OctoPrint will also call the :func:`on_plugin_enabled` callback on its implementation
+(if it exists). Likewise, when a plugin gets disabled OctoPrint will call the :func:`on_plugin_disabled` callback on
+its implementation (again, if it exists).
+
Some plugin types require a reload of the frontend or a restart of OctoPrint for enabling/disabling them. You
can recognize such plugins by their implementations implementing :class:`~octoprint.plugin.ReloadNeedingPlugin` or
:class:`~octoprint.plugin.RestartNeedingPlugin` or providing handlers for one of the hooks marked correspondingly.
+For these plugins, disabling them will *not* trigger the respective callback at runtime as they will not actually
+be disabled right away but only marked as such so that they won't even load during the required restart.
+
+Note that uninstalling a plugin through the bundled Plugin Manager will make a plugin first get disabled and
+then unloaded, but only if it doesn't require a restart. Plugins wishing to react to an uninstall through the
+Plugin Manager may implement :func:`~octoprint.plugin.types.OctoPrintPlugin.on_plugin_pending_uninstall` (added in OctoPrint 1.8.0) which will always be called by the Plugin Manager,
+regardless of whether the plugin requires a restart of OctoPrint to be fully uninstalled or not. Please be aware
+that the Plugin Manager is not the only way to uninstall a plugin from the system, a user may also uninstall it
+manually through the command line, circumventing Plugin Manager completely.
.. image:: ../images/plugins_lifecycle.png
:align: center