I sometimes end up in a situation where I'm working with a generator whose members are themselves generators (and so on for n levels).
When debugging, printing these results in the useless <generator object blah at blah>
Obviously I can do print(list(my_gen))
to convert the top level to a list. But then I get
[<generator object blah at blah>, <generator object blah at blah>, <generator object blah at blah>]
which is equally useless.
Is there a simple command for printing a nested generator evaluated all the way down?
I know that I could write a recursive function to do this, but I'm looking for a simple method.