Improve default error reporting (debug mode via middleware for error event)

Aperta
#344 0 commenti 0 reazioni 0 assegnatari Vedi su GitHub

Nessuno ha ancora preso questa issue.

Valutazione

Difficoltà
5/5
Tempo stimato
Più di una settimana
Idoneità per principianti
20/100
Tipo di issue
Funzionalità
Chiarezza
Da chiarire
Stato di attività
Ferma
Stack tecnologico
php

Direzione di ricerca

Start with the proposal in issue #344 and the related documentation issue #342. No files, tests, or entry points are identified, and the behavior is still open to design decisions around debug output, proxy-aware IP limits, logging, and custom error handlers. Done cannot be defined until those choices are resolved.

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

Descrizione

help wanted maintenance question

I've just filed #342 to improve documentation for error handling for invalid requests and invalid responses respectively. This is only a first step because this keeps coming up and I think we agree it's about time to add some better default error handing logic.

This ticket aims to serve as a base to discuss how "default error handling logic" could look like.

For instance, we might want to just dump any Exception/Throwable including the full stack trace, but this may leak some application details to the outside. We may want to limit this to certain IP ranges only, but this won't work behind a reverse proxy anymore. We may want to add a "debug" flag or a DebugMiddleware, but this requires some explicit choice. We may want to respect PHP's error_reporting value, but it's unclear if this is how people understanding this configuration. We may want to log to STDERR instead of the response message, but it's unclear what effect this could have on existing deployments. We may want to apply our "default error handling logic" only if no explicit error is given, but it's unclear if this is what people expect when they start adding custom error handling logic.

Any input is welcome 👍

Lingua principale
PHP
Stelle
781
Fork
166
Metriche di merge delle PR
Nessuna PR unita negli ultimi 30g

Guida per i contributori

Nessuna guida per i contributori indicizzata per questo repository

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 reactphp/http

Tutte le issue di reactphp/http

Issue simili

Altre issue su PHP

Ricevi le nuove issue nella tua casella

Un breve riepilogo di issue GitHub adatte ai principianti.