client
client copied to clipboard
ACLOracles: detect and include contextual error message
Is your feature request related to a problem? Please describe. If a user is given an error, it'd be nice to make the error as descriptive as possible.
"You may not have the required permissions" doesn't tell the user much.
Here's a specific example:

This is from the Dandelion template. The specific problem is that the user did not have the Token Lock token (or enough of those tokens) to create a new vote.
A preferable error message would be something like:
You must have a minimum balance of 10 DAI to create a new vote.
There are other similar situations as well where we could be more descriptive about what exactly the issue is preventing a user from acting:
- Do they need a token?
- Do they need more tokens?
- Do they need to be given permission directly?
If a user currently doesn't have permission to perform an action, let's give them the information they need so they know what they need to do to be able to take the action.
This is similar to https://github.com/aragon/aragon/issues/1292, but I've repurposed this to be specific to ACLOracles.
The specific problem with Dandelion (and its usage of ACLOracles) results in similar symptoms to #1292, but can be solved separately.