Elena' s AI Blog

Python Projects & Utilities Series

Elena Daehnhardt

Midjourney AI-generated art
Image credit: Illustration created with Midjourney, prompt by the author.
Image prompt

“An illustration representing cloud computing”

Python Projects & Utilities

Project-oriented Python posts that sit between fundamentals and advanced AI engineering.

Posts in This Series

Part 1: Loop like a Pro with Python Iterators

This post explains the basics of Python iterators and their successful alternatives, such as list comprehension. While these alternatives use more memory, they are still useful in practice. The post also covers advanced techniques for working with iterators, including using the itertools module and creating generators with the yield keyword. By mastering iterators, readers can create elegant and efficient code and become better Python programmers.

Part 2: Joking Flask App

Build a joke-serving web app with Flask from scratch. We cover routing, Jinja2 templates, static files, form handling, and how to avoid the classic "request is not defined" trap.

Part 3: What is Docker?

Docker lets you quickly deploy microservices, cloud-native architectures, or web apps. In this post, we will use Docker to create a reliable environment for Flask applications that efficiently manages dependencies and deployment intricacies.

Part 4: Logging in Python

In this post, I cover everything from the basics of logging to configuring logging to output messages to different destinations. I also included some examples of logging levels and how to log messages at different levels based on the severity of the issue.

Part 5: Python Virtual Environments

If you are working on multiple Python projects, you will eventually run into a dependency nightmare. Virtual environments solve this by isolating packages per project. Here is my practical guide to creating, managing, and safely deleting Python virtual environments.

Part 6: Python Flask TODO App

Ready to build your first web application? In this tutorial, we will construct a fully functional TODO app using Python, Flask, and SQLite. You will learn how to route requests, manage a database, and render HTML templates.

All Posts