Skip to content

Commit 31fd071

Browse files
author
Simon Prickett
authored
Merge pull request #120 from gowthamparuchuru/main
corrected Strict Validation documentation
2 parents 6cd611b + 627b976 commit 31fd071

File tree

1 file changed

+4
-4
lines changed

1 file changed

+4
-4
lines changed

docs/getting_started.md

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -465,15 +465,15 @@ try:
465465
first_name="Andrew",
466466
last_name="Brookins",
467467
468-
join_date="2020-01-02", # <- A date as a string shouldn't work now!
469-
age="38"
468+
join_date="2020-01-02",
469+
age="38" # <- Age as a string shouldn't work now!
470470
)
471471
except ValidationError as e:
472472
print(e)
473473
"""
474474
pydantic.error_wrappers.ValidationError: 1 validation error for Customer
475-
join_date
476-
Value must be a datetime.date object (type=value_error)
475+
age
476+
Value is not a valid integer (type=type_error.integer)
477477
"""
478478
```
479479

0 commit comments

Comments
 (0)