...
Plugins are currently supported using the python programming language.
Anatomy of a plugin
A plugin requires the following fields to ensure it is set up and registered by the plugin loader:
...
The plugin_type is used to register the type of the plugin. This is arbitrary, although guidelines (e.g. custom-rating) will be provided soon. The name registers the plugins name with the plugin system.
Caveats
The database cannot be assumed to be available during plugin load time. Therefore no module-level code in the plugin file should perform any action that requires database connectivity, directly or indirectly.
Example: custom rating plugin
The following example shows the implementation of a custom rating system for use within Canopy:
...
TODO: provide additional examples.
Installing plugins
Once you're ready to run your plugin, it needs to be installed. For further information on this, see: Installing plugins and management commands.
Further improvements
The plugin framework will be improved over the coming releases. Identified areas of improvement include:
...