g is for get_or_create Django's get_or_create is great. It lets you search for s...
Juhis @hamatti@mastodon.world
g is for get_or_create
Django's get_or_create is great. It lets you search for something in the database and create it if it didn't exist.
It's such a great tool for things like data entry and makes the code nice and easy to read and follow.
https://hamatti.org/posts/g-is-for-get-or-create-python-a-to-z/