How to tame your Python dictionaries with dataclasses, marshmallow and desert

Ness Phan
Python in Plain English
5 min readJan 8, 2021

--

People who write Python like dictionaries. People who write a lot of Python hate dictionaries. And it’s easy to see why! It’s tempting and easy to pass around random information between functions and modules as dictionaries, define your configs as dictionaries, process API responses as dictionaries…and it gets unwieldy fast.

In this article, we will be taking about:

  1. How we can tame dictionaries with dataclasses.

--

--

Software Engineer with a passion for making music, art and writing about software