Thanks to visit codestin.com
Credit goes to github.com

Skip to content

[Messenger][Serializer] Support ValidationFailedException normalization #51739

@MatTheCat

Description

@MatTheCat

Description

The validation middleware throws Symfony\Component\Messenger\Exception\ValidationFailedExceptions. You can map them to a 400 status code, but violations won’t be part of the response because the ProblemNormalizer will only consider Symfony\Component\Validator\Exception\ValidationFailedException.

Would it be possible to handle Symfony\Component\Messenger\Exception\ValidationFailedException the same way, so that a conversion step isn’t needed? Or should the ValidationMiddleware throw Symfony\Component\Validator\Exception\ValidationFailedExceptions?

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