application#

Description#

This plugin is used to control and inspect the application state.

Configuration#

application:
    # No configuration required

Actions#

Module reference#

class platypush.plugins.application.ApplicationPlugin(**kwargs)[source]#

Bases: Plugin

This plugin is used to control and inspect the application state.

__init__(**kwargs)#
get_install_commands(extension: str) List[str][source]#

Get the installation commands for an extension.

Parameters:

extension – Extension name. For plugins, it will be the plugin name (e.g. light.hue or music.mpd); for backend, the name will be prefixed by backend. (e.g. backend.http or backend.tcp).

get_pending_actions() List[dict][source]#

Get the list of actions being executed or pending execution.

Format:

[
    {
        "id": "action_id",
        "action": "plugin.action_name",
        # Current running time in seconds
        "running_time": 3.14,
        "args": {
            "arg1": "value1",
            ...
        }
    },
    ...
]
install(extension: str)[source]#

Install the dependencies of an extension.

Parameters:

extension – Extension name. For plugins, it will be the plugin name (e.g. light.hue or music.mpd); for backend, the name will be prefixed by backend. (e.g. backend.http or backend.tcp).

restart()[source]#

Restart the application.

stop()[source]#

Stop the application.