StefanSchenk
New Contributor II

Here's one that might help:

def deep_ls(path: str):
    """List all files in base path recursively."""
    for x in dbutils.fs.ls(path):
        if x.path[-1] is not '/':
            yield x
        else:
            for y in deep_ls(x.path):
                yield y

Usage:

https://gist.github.com/Menziess/bfcbea6a309e0990e8c296ce23125059