Do you understand how a hash table works? What if you could learn about building one while practicing test-driven development? What are best practices when designing a REST API? This week on the show, Christopher Trudeau is here, and he’s brought another batch of PyCoder’s Weekly articles and projects.
We talk about the recent Real Python article “Build a Hash Table in Python With TDD.” The tutorial shows how to implement a hash table prototype from scratch in Python. It also provides a hands-on crash course in test-driven development.
Christopher shares an article on designing REST APIs and provides some of his own best practices. We cover authentication implementation, good naming conventions, versioned APIs, and ways to specify dates.
We cover several other articles and projects from the Python community, including a news roundup, a PEP on removing dead batteries from the standard library, a comparison of the Python list vs tuple, a guide to writing user-friendly CLIs in Python, just enough Cython to be useful, a cross-platform TUI and ASCII animation package, and code for running black on Python code blocks in documentation files.
Course Spotlight: Command Line Interfaces in Python
Command-line arguments are the key to converting your programs into useful and enticing tools that are ready to be used in the terminal of your operating system. In this course, you’ll learn their origins, standards, and basics, and how to implement them in your program.
00:00:00 – Introduction00:02:23 – PEP 594: Removing Dead Batteries From the Standard Library00:05:33 – Python 3.10.3, 3.9.11, 3.8.13, and 3.7.13 Now Available 00:08:37 – EuroPython 2022: Ticket Sales Open00:09:34 – Python list vs tuple Comparison00:12:19 – How to Write User-Friendly CLIs in Python00:20:14 – Sponsor: Anvil00:20:55 – Build a Hash Table in Python With TDD00:26:11 – Just Enough Cython to Be Useful00:36:21 – Video Course Spotlight00:37:45 – How to Design Better REST APIs00:47:10 – blacken-docs: Run black on Python Code Blocks within Documentation Files00:49:09 – asciimatics: Cross Platform TUI and ASCII Animation Package00:52:03 – Thanks and goodbyePEP 594: Removing Dead Batteries From the Standard LibraryPython 3.10.3, 3.9.11, 3.8.13, and 3.7.13 Now AvailableEuroPython 2022: Ticket Sales OpenPython list vs tuple Comparison – Learn how list and tuple are similar and how they’re different, including storage and speed differences and how to choose between them.How to Write User-Friendly CLIs in Python – Learn how to write user-friendly command-line interface applications and an overview of several of the popular CLI libraries: argparse, Click, Typer, Docopt, and Fire.Build a Hash Table in Python With TDD – In this step-by-step tutorial, you’ll implement the classic hash table data structure using Python. Along the way, you’ll learn how to cope with various challenges such as hash code collisions while practicing test-driven development (TDD).Just Enough Cython to Be Useful – Cython is a superset of Python designed to give C-like performance. Ever wanted to learn the basics? This article shows you how to get started.How to Design Better REST APIs – Fifteen language-agnostic tips on REST API design, including good naming conventions, ways to specify dates, versioned APIs, authentication keys, pagination, and when to use which HTTP methods.blacken-docs: Run black on Python Code Blocks in Documentation Filesasciimatics: Cross Platform TUI and ASCII Animation PackageCommand Line Interface Guidelines - An Open-Source GuideHow to Build Command Line Interfaces in Python With argparse – Real PythonCommand Line Interfaces in Python – Real Python Language Basics — Cython 3.0.0a10 documentationBuilding HTTP APIs With Django REST Framework – Real PythonPython Timer Functions: Three Ways to Monitor Your Code – Real PythonLevel up your Python skills with our expert-led courses:
Lists and Tuples in PythonCommand Line Interfaces in PythonRock, Paper, Scissors With Python: A Command Line Game Support the podcast & join our community of Pythonistas