DevPath

Validate a request payload with specific errors

Foundation · practical lab · 20 min · runtime python

Brief

Write parse_user(payload: dict) -> User that raises a ValidationError listing every missing or incorrectly typed field, and never uses a bare except.

3 progressive hints are available in the editor.

Public checks

  • collects all errors — expected: ValidationError with name and age