Skip to content

Commit

Permalink
fix: normalize failed to update metadata error message (#1789)
Browse files Browse the repository at this point in the history
  • Loading branch information
0xKheops authored Jan 24, 2025
1 parent d20764a commit ecb9178
Showing 1 changed file with 2 additions and 4 deletions.
6 changes: 2 additions & 4 deletions packages/extension-core/src/util/getMetadataDef.ts
Original file line number Diff line number Diff line change
Expand Up @@ -132,11 +132,9 @@ const getMetadataDefInner = async (
return CACHE_RESULTS.get(cacheKey)
} catch (cause) {
if ((cause as Error).message !== "RPC connect timeout reached") {
// not a useful error, do not log to sentry
const message = `Failed to update metadata for chain ${genesisHash}`
const error = new Error(message, { cause })
const error = new Error("Failed to update metadata", { cause })
log.error(error)
sentry.captureException(error, { extra: { genesisHash } })
sentry.captureException(error, { extra: { genesisHash, chainId: chain?.id ?? "UNKNOWN" } })
}
metadataUpdatesStore.set(genesisHash, false)
}
Expand Down

0 comments on commit ecb9178

Please sign in to comment.