Improve error dialogs #62
Labels
No labels
ci
crate/dtmm
crate/dtmt
crate/sdk
crate/serde_sjson
kind
bug
kind
documentation
kind
enhancement
kind
feature
kind
question
kind
upstream
part/bundle
part/filetype
stage
actionable
stage
design
stage
proposal
status/duplicate
status/good first issue
status/help wanted
status/invalid
status
need-replicate
status/wontfix
No milestone
No project
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set.
Reference: bitsquid_dt/dtmt#62
Loading…
Add table
Reference in a new issue
No description provided.
Delete branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Fork
color_eyre
to expose more of itsHandler
's internal details, such assections
. Then I can use those to compose a custom representation of the error in the dialogs, rather than the default debug print.While the full error chain is quite helpful to track an error in code, for user errors, only the root cause is generally helpful.
So the error dialogs should probably only display the top-most error, since that usually describes the operation that the user wanted to perform, and the bottom-most one, as that is where it actually failed.
For additional context, I might also want to provide the entry right above the root cause. E.g. when it's an IO error, I usually add the path as context above that.
Potential template:
Failed to deploy mods!
Failed to write deployment data to 'path/to/deployment': No such file or directory
Suggestion: Make sure the 'Game Directory' setting is correct.