Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Plugin API improvements #4603

Merged
merged 5 commits into from
Feb 22, 2024

Conversation

WithoutPants
Copy link
Collaborator

These changes are intended to improve the external interface provided for plugins. These interfaces are meant for custom plugin UIs to call.

  • Makes the task_name parameter in runPluginTask optional. If no task_name is provided, then the plugin interface is executed without any additional arguments that might be provided by a task config. This method of running a plugin task is intended for plugins that want to run tasks using the task queue but don't want to expose the task in the stock UI.
  • Deprecates args in runPluginTask in favour of the more generic args_map map input.
  • Adds a description parameter in runPluginTask, which will be used in the task queue description, which is otherwise defaulted to the description in the task config if task_name is provided, or the plugin ID otherwise.
  • Adds a new runPluginOperation which runs a plugin with the supplied arguments immediately, not using the task management system, and returns the result provided by the Output field of the plugin. Returns an error if the Error field is populated.

@WithoutPants WithoutPants added the feature Pull requests that add a new feature label Feb 21, 2024
@WithoutPants WithoutPants added this to the Version 0.25.0 milestone Feb 21, 2024
@WithoutPants WithoutPants merged commit 0c2a219 into stashapp:develop Feb 22, 2024
2 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
feature Pull requests that add a new feature
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

1 participant