If I understand correctly, you want to change the permissions of each individual directory along a tree path, creating each directory beforehand if it doesn't exist.
I don't think that there is a function doing exactly that, and I don't know any other way than changing each directory of the path. That means in a loop.
Except if you accept to :
rely on the OS commands
Change also the directories files permissions
Then you could issue a "chmod -R" shell command on the top-most directory.
What is dest_root
"? Shouldn't it be current_dir
?
If you just need to create a directory tree with the given permissions, os.makedirs as a mode parameter.