tubeshowcaseโ—1,157,887 videosโ™ก My collection 0
โ† Learn to Code

Learn to Code14:30

Why Dataclasses Disappear in Real Python Applications

ArjanCodes โ†—

From the creator

๐Ÿ’ก Learn how to design great software in 7 steps: https://arjan.codes/designguide. In this video, I take a deep dive into Python dataclasses in 2025. Are they still useful now that we have Pydantic, FastAPI, SQLAlchemy, and other tools? I walk through real-world examples showing when you should use dataclasses, Pydantic models, and how to design your models cleanly. Iโ€™ll also build a small FastAPI app with SQLAlchemy and SQLite to demonstrate proper separation between domain models and API schemas. ๐Ÿ”ฅ GitHub Repository: https://git.arjan.codes/2025/dataclasses. ๐ŸŽ“ ArjanCodes Courses: https://www.arjancodes.com/courses. ๐Ÿ’ฌ Join my Discord server: https://discord.arjan.codes. โŒจ๏ธ Keyboard Iโ€™m using: https://amzn.to/49YM97v. ๐Ÿ”– Chapters: 0:00 Intro 1:11 Quick Refresher โ€“ What Are Dataclasses? 4:09 Dataclasses vs Pydantic โ€“ And a Real FastAPI Example 6:36 Separate Domain and API Models 8:51 Hybrid Approach in Pydantic 11:53 When Do I Use Dataclasses 14:03 Final Thoughts #arjancodes #softwaredesign #python

Published 2025-06-27 ยท Watch on YouTube โ†—
Availability and playback restrictions are controlled by the original channel.

Keep exploring Learn to Code