Engineering
Production code quality, benchmarking, and algorithmic tooling. Study unit test mocking, micro-benchmarking, dictionary merging, and bitwise operations.
Chapter Lessons
Mocking
Mocking objects is a common strategy that developers use to test code that depends on an external system or external resources for it to work properly. This module shows how to use mocking to modify an application server so that it is easier to test.
Benchmark
As programs increase in size, they have the risk of getting slow as new features are added and extra layers of complexity to the main features. Benchmarking is an approach that helps developers use profiling metrics and their code intuition to optimize programs further. This module uses cProfile to compare the performance of two functions with each other, showcasing the impact of caching/memoization with `functools.cache`.
Memory Profile
While CPU profiling (`cProfile`) identifies execution bottlenecks, memory profiling diagnoses RAM consumption, high allocations, and memory leaks.
Logger
Production software requires observability into application state, diagnostic events, and unexpected errors.
Bitwise
Bitwise operators manipulate integers at the individual bit level, serving as essential tools in systems engineering, low-level protocols, and optimization.