Skip to content

Improve and Standardize Error Handling and Logging Strategy #6

@AbdulRashidReshamwala

Description

@AbdulRashidReshamwala

Improve and Standardize Error Handling and Logging Strategy

Description

While we already use pino for logging in our SDK, our error handling approach is inconsistent across the codebase. We need to standardize our error handling and improve our use of the existing logging system to enhance debugging, error reporting, and overall reliability of the SDK. Some error messages donot provide the entire context on what caused the issue and what action user to take to solve the issue.

//eg: does not give us the entire information what can cause the identifier mismatch 
//and there are no logs showing what is the expected identifier and what was the indetifier that was calculated
throw new ProofNotVerifiedError('Identifier Mismatch')

Goals

  • Implement a consistent error handling mechanism across the SDK
  • Standardize the use of the existing pino logger
  • Create custom error types for better error identification
  • Improve error messages for better developer experience

Current State

We currently use pino for logging:

Metadata

Metadata

Assignees

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions