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

Re-think command storage to associate different implementations of same command with each other #26

Closed
kangalio opened this issue Nov 11, 2021 · 1 comment

Comments

@kangalio
Copy link
Collaborator

kangalio commented Nov 11, 2021

This issue is a continuation of the discussion in #19.

Problem

Poise currently generates multiple command objects per function, corresponding to each command type (prefix, slash, context menu). These command objects are stored completely separate from each other in PrefixFrameworkOptions and ApplicationFrameworkOptions respectively.

This makes it hard to tell which command invocations belong to the same command at runtime, which is needed for many things:

In #19 we discussed several ideas to redesign how commands are stored in order to fix the issues. But after thinking about each of them and starting to implement a couple in feature branches, none of them seemed great.

I'm currently relatively demotivated to work on this issue because to me it feels like no good solution is in sight. This issue functions as a reminder/placeholder for now, or as a place of discussion for ideas for solutions

@kangalio
Copy link
Collaborator Author

kangalio commented Dec 4, 2021

By exploring several of the brainstormed design ideas again, the Arc<CommandId> way turned out to be the most straightforward that also addresses all current design issues

@kangalio kangalio closed this as completed Dec 4, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

1 participant