Book: Hexagonal Architecture in Python
Companion code: hexagonal-python-examples — every listing from the book, free on GitHub
My project: Hermes IDE | GitHub — an IDE for developers who ship with Claude Code and other AI coding tools
Me: xgabriel.com | GitHub
Your FastAPI service is slow only under real traffic. Locally every endpoint answers in a few milliseconds. The obvious move is to restart the worker under cProfile , and that is the move that ruins the measurement: you lose the warm state, and the profiler you just added slows down every function call in the process you wanted to observe.
Python 3.15.0 shipped on October 9, 2026 (3.15.2 is the current patch release) with a different option in the standard library. It is called Tachyon, it lives at profiling.sampling , and it attaches to a process that is already running, by PID, without restarting it or adding code to it.…