Some struggle with recursion, but as package invocation_tree visualizes the Python call tree in real time, it gets easy to understand what is going on and to debug any remaining issues.
See this one-click Quick Sort demo in the Invocation Tree Web Debugger: