From 25651a8e7a940791d1984c4c519bb1a40712f145 Mon Sep 17 00:00:00 2001 From: nabarun Date: Mon, 8 Apr 2024 04:04:13 +0000 Subject: [PATCH] Add context to error message (#11) Part of [Fix error propagation from laconicd to client SDK](https://www.notion.so/Fix-error-propagation-from-laconicd-to-client-SDK-1bd20c5a4e8141a99e5809ea1fd7832f) and [Create laconic registry SDK](https://www.notion.so/Create-laconic-registry-SDK-d3a636d4aba44f7cbba3bd99b7146811) - Use error in response raw log from laconicd - TODO: Add error examples Co-authored-by: neeraj Reviewed-on: https://git.vdb.to/cerc-io/registry-sdk/pulls/11 --- package.json | 2 +- src/laconic-client.ts | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/package.json b/package.json index 131a33a..17d7150 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "@cerc-io/registry-sdk", - "version": "0.2.1", + "version": "0.2.2", "main": "dist/index.js", "types": "dist/index.d.ts", "repository": "git@github.com:cerc-io/registry-sdk.git", diff --git a/src/laconic-client.ts b/src/laconic-client.ts index f8b65a3..1434f26 100644 --- a/src/laconic-client.ts +++ b/src/laconic-client.ts @@ -383,6 +383,6 @@ export class LaconicClient extends SigningStargateClient { console.error(error); } - return errorMessage || DEFAULT_WRITE_ERROR; + return `${errorMessage || DEFAULT_WRITE_ERROR}: ${error}`; } }