filmov
tv
Do We Still Need Dataclasses? // PYDANTIC Tutorial

Показать описание
Pydantic is a very useful package that makes dealing with data much easier, similar to what Python's built-in dataclasses do. Where Pydantic shines is in dealing with validating and sanitizing data. In this tutorial video, I show you how it works, and when to choose Pydantic over dataclasses in your code projects.
🎓 Courses:
A few interesting links to articles and books:
👍 If you enjoyed this content, give this video a like. If you want to watch more of my upcoming videos, consider subscribing to my channel!
👀 Channel code reviewer board:
- 0xUnicorn
- Ryan Laursen
- Sybren A. Stüvel
🔖 Chapters:
0:00 Intro
0:52 Explaining the example
1:54 Creating a Pydantic Basemodel
4:42 Adding field validation
9:47 Adding model-level validation
12:54 More possibilities by adding a Config class
14:03 Converting the model instances to a dictionary
14:38 Other things that Pydantic can do
15:38 So, are dataclasses obsolete?
#arjancodes #softwaredesign #python
DISCLAIMER - The links in this description might be affiliate links. If you purchase a product or service through one of those links, I may receive a small commission. There is no additional charge to you. Thanks for supporting my channel so I can continue to provide you with free content each week!
🎓 Courses:
A few interesting links to articles and books:
👍 If you enjoyed this content, give this video a like. If you want to watch more of my upcoming videos, consider subscribing to my channel!
👀 Channel code reviewer board:
- 0xUnicorn
- Ryan Laursen
- Sybren A. Stüvel
🔖 Chapters:
0:00 Intro
0:52 Explaining the example
1:54 Creating a Pydantic Basemodel
4:42 Adding field validation
9:47 Adding model-level validation
12:54 More possibilities by adding a Config class
14:03 Converting the model instances to a dictionary
14:38 Other things that Pydantic can do
15:38 So, are dataclasses obsolete?
#arjancodes #softwaredesign #python
DISCLAIMER - The links in this description might be affiliate links. If you purchase a product or service through one of those links, I may receive a small commission. There is no additional charge to you. Thanks for supporting my channel so I can continue to provide you with free content each week!
Комментарии