Remove `AVM_PRINT_PROCESS_CRASH_DUMPS`

Aperta
#2,050 1 commento 0 reazioni 0 assegnatari Vedi su GitHub

I maintainer di solito rispondono entro 2 giorni

Nessuno ha ancora preso questa issue.

Valutazione

Difficoltà
4/5
Tempo stimato
3-5 giorni
Idoneità per principianti
35/100
Tipo di issue
Funzionalità
Chiarezza
Abbastanza chiara
Stato di attività
Ferma
Stack tecnologico
c, erlang

Direzione di ricerca

Start by reading PRs #1799 and #2049 to understand the existing crash dump workaround and the failure case. Then trace how globalcontext stores and uses the logger PID and where system_flag handles system_logger; the issue gives no file or test names. Done means an alive logger suppresses context_dump() at runtime, while the default behavior uses avm_context_dump when no logger is configured.

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

Descrizione

PR #1799 introduced AVM_PRINT_PROCESS_CRASH_DUMPS since "The OTP relies on the logger to print information about abruptly terminated processes, and so we try to do in Popcorn, thus we need to disable the crash dumps.".
That PR was a reasonable workaround however it introduces an additional option that can be configured only at build time. Also if a crash happens without having a logger enabled, processes (or even the VM) terminates without any explaination (see PR #2049).

A different approach should be investigated: globalcontext should remember the logger PID, so if there is an alive logger, crash dumps are never printed using context_dump(). This basically makes AVM_PRINT_PROCESS_CRASH_DUMPS behavior configurable at runtime.

This can be done with system_flag(system_logger, logger | undefined | pid()) -> logger | undefined | pid(). In AtomVM will use avm_context_dump as a default.

Lingua principale
Erlang
Stelle
2.3k
Fork
171
Merge medio
5g 11h
PR unite (30g)
19

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 atomvm/AtomVM

Tutte le issue di atomvm/AtomVM

Issue simili

Altre issue su Backend & API Design

Ricevi le nuove issue nella tua casella

Un breve riepilogo di issue GitHub adatte ai principianti.