-
-
Notifications
You must be signed in to change notification settings - Fork 3k
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
cli: errors are displayed twice #300
Comments
@maybebtc which fish prompt/theme do you use? |
Ah, nice! I approve! I just use a simple robbyrussel git info prompt. |
In ipfs2 main, when the program decides what to write out to the user (based on result of command execution), what is the significance of commands.Response.Error.Code? What I am reading is... a) If the code is not b) If the code is However, having read through the source, I do not feel confident in my ability to predict how the framework will classify the wide range of errors into these two classes. Is there a principle behind the distinction? The reason this is important is that the code appears to dictate the result displayed to the user: This seems to be an ErrNormal:
This is an ErrClient:
@mappum can you help me understand? |
@maybebtc The essential difference between the two is that For example, not providing a required argument would be an An error like timing out when trying to resolve an IPNS name would be an |
@mappum yeah there is a semantic distinction, but how are they distinguished in the code? who decides what the error is? Does each function -- on finding an error -- get to set wheter it's an ErrClient or ErrNormal? i think the main concern is about how obvious it is to a user. |
@jbenet thank you for getting to the kernel. How are they distinguished in code? What components are responsible for classification? |
I fixed this Issue. @maybebtc can you verify and close? |
see
ipfs2 add
at fd9ffb5The text was updated successfully, but these errors were encountered: