chore: Improve console error experience (#124)

* chore: Improve console error experience

* fix: Use standard error code and handle verbosity
This commit is contained in:
Abhisek Datta
2026-01-17 14:05:01 +05:30
committed by GitHub
parent 80a1747e3e
commit 6a3821d44a
6 changed files with 438 additions and 34 deletions
+16
View File
@@ -0,0 +1,16 @@
package usefulerror
// Standard error codes that can be re-used across the project.
// We will use a human friendly format for the error codes and not align with posix error codes.
// Keep this minimal. Reuse first before adding new ones.
const (
ErrCodeInvalidArgument = "InvalidArgument"
ErrCodePermissionDenied = "PermissionDenied"
ErrCodeNotFound = "NotFound"
ErrCodeTimeout = "Timeout"
ErrCodeCanceled = "Canceled"
ErrCodeUnexpectedEOF = "UnexpectedEOF"
ErrCodeUnknown = "Unknown"
ErrCodeLifecycle = "Lifecycle"
ErrCodeNetwork = "Network"
)