Skip to content

Debug\ExceptionHandler should have a JSON output option #26448

Closed
@nesl247

Description

@nesl247
Q A
Bug report? no
Feature request? yes
BC Break report? no
RFC? no
Symfony version 4.0.6

It would be great if Debug\ExceptionHandler had an option to output JSON. This is more relevant than ever with the new symfony/flex ideology IMO. Symfony is being used for API development more than ever, and having HTML output while running API spec testing, dredd, behat, etc. makes it really hard to see what the issue is.

Because this could happen before the kernel is booted, my suggestion is to have the option be done when calling Debug::enable() or new Kernel() or something early on if content-negotiation is not possible.

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions