Skip to content

Commit

Permalink
📝 update readme
Browse files Browse the repository at this point in the history
  • Loading branch information
yanyongyu authored Jan 10, 2024
1 parent 1990a35 commit 7dd2510
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -368,10 +368,10 @@ event = parse_without_name(request.body)
```

> [!WARNING]
> The `parse_without_name` function will try to parse the payload with all supported event names.
> The behavior of this function is not the same between pydantic v1 and v2.
> When using pydantic v1, the function will return the first valid event model (known as `left-to-right` mode).
> When using pydantic v2, the function will return the highest scored valid event model (known as `smart` mode).
> The `parse_without_name` function will try to parse the payload with all supported event names.
> The behavior of this function is not the same between pydantic v1 and v2.
> When using pydantic v1, the function will return the first valid event model (known as `left-to-right` mode).
> When using pydantic v2, the function will return the highest scored valid event model (known as `smart` mode).
> See: [Union Modes](https://docs.pydantic.dev/latest/concepts/unions/#union-modes).

Parse dict like payload:
Expand Down

0 comments on commit 7dd2510

Please sign in to comment.