Skip to content

Commit

Permalink
fix: sentry tags (#8953)
Browse files Browse the repository at this point in the history
  • Loading branch information
guanbinrui committed Mar 6, 2023
1 parent a3a9cf1 commit 6774b6d
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 2 deletions.
6 changes: 6 additions & 0 deletions packages/web3-providers/src/Sentry/index.ts
Expand Up @@ -58,8 +58,14 @@ export class SentryAPI implements TelemetryAPI.Provider<Event, Event> {
Sentry.setTag('agent', getAgentType())
Sentry.setTag('site', getSiteType())
Sentry.setTag('extension_id', getExtensionId())
Sentry.setTag('channel', process.env.channel)
Sentry.setTag('version', process.env.VERSION)
Sentry.setTag('ua', navigator.userAgent)
Sentry.setTag('engine', process.env.engine)
Sentry.setTag('build_date', process.env.BUILD_DATE)
Sentry.setTag('branch_name', process.env.BRANCH_NAME)
Sentry.setTag('commit_date', process.env.COMMIT_DATE)
Sentry.setTag('commit_hash', process.env.COMMIT_HASH)
}

// The sentry needs to be opened at the runtime.
Expand Down
2 changes: 0 additions & 2 deletions packages/web3-providers/src/helpers/captureFetchException.ts
Expand Up @@ -7,8 +7,6 @@ export async function captureFetchException(request: Request, response?: Respons
response_type: response?.type,
status_code: response?.status,
status_text: response?.statusText,
},
extra: {
request_headers: JSON.stringify(Object.fromEntries(request.headers.entries())),
request_body: await getRequestJSON(request.clone()),
request_text: await getRequestText(request.clone()),
Expand Down

0 comments on commit 6774b6d

Please sign in to comment.