Skip to content

Commit d3814cd

Browse files
authored
add identifier to pkarr error for debugging purposes (#508)
* add identifier to pkarr error for debugging purposes * add changeset
1 parent d863c37 commit d3814cd

File tree

2 files changed

+6
-1
lines changed

2 files changed

+6
-1
lines changed

.changeset/tall-mugs-wink.md

+5
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,5 @@
1+
---
2+
"@web5/dids": patch
3+
---
4+
5+
We sometimes get failures in CI publishing to the DHT. In order to make debugging these errors easier, we add the identifier to the error thrown.

packages/dids/src/methods/did-dht.ts

+1-1
Original file line numberDiff line numberDiff line change
@@ -948,7 +948,7 @@ export class DidDhtDocument {
948948
});
949949

950950
} catch (error: any) {
951-
throw new DidError(DidErrorCode.InternalError, `Failed to put Pkarr record: ${error.message}`);
951+
throw new DidError(DidErrorCode.InternalError, `Failed to put Pkarr record for identifier ${identifier}: ${error.message}`);
952952
}
953953

954954
// Return `true` if the DHT request was successful, otherwise return `false`.

0 commit comments

Comments
 (0)