Record error details when a wizard crashes

Aperta
#1,399 1 commento 0 reazioni 0 assegnatari Vedi su GitHub

I maintainer di solito rispondono entro 1 giorno

Nessuno ha ancora preso questa issue.

Valutazione

Difficoltà
4/5
Tempo stimato
3-5 giorni
Idoneità per principianti
40/100
Tipo di issue
Funzionalità
Chiarezza
Abbastanza chiara
Stato di attività
Attiva
Stack tecnologico
typescript
Ambito
observability

Direzione di ricerca

Start in src/telemetry.ts, especially withTelemetry and beforeSend, and read the existing telemetry tests to see how events are asserted. The proposal names the safe fields to consider, but the message-sanitization policy still needs a decision before implementation. Done means crash events can be grouped by step plus allowlisted error details, and tests confirm that paths and stack traces are not sent.

Scritto dal modello di indicizzazione a partire dal testo della issue.

Descrizione

bug Errors
Problem

When a wizard crashes, our telemetry does not tell us why. withTelemetry in src/telemetry.ts discards the caught error and captures a constant string:

} catch (e) {
  Sentry.captureException('Error during wizard execution.');

beforeSend also removes stack traces. The events still carry tags such as integration and progress (the last step started), but no error name, message or code. Different crashes end up with the same message, so we cannot tell which bugs users hit or whether a fix worked.

Proposal

Record enough about the original error to tell crashes apart, for example:

  • the error name
  • the error code, such as ENOENT, if there is one
  • a sanitized message, if we decide that is safe

Use these details, together with the step, for grouping.

Privacy constraints

Raw errors must not be sent as they are:

  • Stack traces may contain absolute paths, which is why they are stripped today.
  • Messages can contain absolute paths, user names, project code or command output.
  • cause and other error properties can contain the same.

An allowlist of safe fields is a good starting point. Whether messages can be included, and how to sanitize them, needs a decision. Tests should check that paths and stack traces are not sent.

Lingua principale
TypeScript
Stelle
297
Fork
88
Merge medio
5h 29m
PR unite (30g)
5

Preparare l'ambiente

Come iniziare

  1. Leggi tutta la issue e poi la guida ai contributi del progetto.
  2. Commenta sulla issue per dire che te ne occupi tu — evita che due persone facciano lo stesso lavoro.
  3. Fai un fork del repository e lavora su un branch.
  4. Apri una pull request che faccia riferimento al numero della issue.

Altre issue di getsentry/sentry-wizard

Tutte le issue di getsentry/sentry-wizard

Issue simili

Altre issue su TypeScript

Ricevi le nuove issue nella tua casella

Un breve riepilogo di issue GitHub adatte ai principianti.