The ways errors are handled is somewhat arbitrary. Generally speaking, we should be returning errors, and errors should be reported to the user in a message handler (or the event loop, which may be more appropriate) rather in auxiliary functions. Errors should be wrapped from predefined error variables, i.e. fmt.Errorf("%w: %w", errPredefinedSomething, err)
.
Runxi Yu referenced this ticket in commit b0afe34.
I think it's pretty much done now. Will check again in the next audit.