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

Update Executor.HOOKS parsing to be more flexible #3079

Open
1 of 3 tasks
bjeffries opened this issue Oct 17, 2024 · 0 comments
Open
1 of 3 tasks

Update Executor.HOOKS parsing to be more flexible #3079

bjeffries opened this issue Oct 17, 2024 · 0 comments
Assignees
Labels
feature feature request

Comments

@bjeffries
Copy link

bjeffries commented Oct 17, 2024

What problem are you trying to solve? Please describe.

The Builder Plugin uses the executor.HOOKS dictionary to hook into the link before it is executed and modify key items in the executor. The parsing of this dictionary is use-case specific and should be generalized to allow for more flexible plugin development (i.e. other plugins can easily add their own hooks to do similar behavior.

Current code:

if executor.HOOKS and executor.language and executor.language in executor.HOOKS:
    await executor.HOOKS[executor.language](ability, executor)

The ideal solution: What should the feature should do?

Update the parsing of the executor.HOOKS dictionary in the planning service and operations api manager to support other HOOKS.

What category of feature is this?

  • UI/UX
  • API
  • Other

If you have code or pseudo-code please provide:

for hook, fcall in executor.HOOKS.items():
    await fcall(ability, executor)
  • [ YES] Willing to submit a pull request to implement this feature?

Additional context
Add any other context or screenshots about the feature request here.

Thank you for your contribution!

@bjeffries bjeffries added the feature feature request label Oct 17, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
feature feature request
Projects
None yet
Development

No branches or pull requests

2 participants