Now I'm curious. What would you say is wrong with python closures? Asking because they feel natural to me, and I haven't run into anything irritating about them. (As opposed to lambdas, which are really annoying and restricted in Python.)
It's not as bad as I thought, but Python doesn't actually have lexical scope, not really. But the LEGB rules mean that it should still work as you expect.
It does if you're using Python 3, which has the nonlocal keyword for lexical scope.