« first day (1953 days earlier)      last day (1625 days later) » 

05:00
Hi, I'm having issue displaying all immediate folder size and total size calculation from a directory path.
import os
from pathlib import Path
root='/dbfs/mnt/datalake/Persistent/Internal/'
size = 0
for path, subdirs, files in os.walk(root):
for f in Path(root).iterdir():
if name in files:
if f.is_dir():
size+=os.path.getsize(os.path.join(path, name))
dirSize = size/(1024*1024)
print(f, "--Size:", dirSize)
print("Directory size=", dirSize/(1024*1024))
What am I doing wrong ?
 
2 hours later…
07:14
1 message moved from Python
 
9 hours later…
15:59
Right now my code looks like this:
```
for . in a, b, c:
do_action("1.level")
for . in 1, 2, 3:
do_action("2.level")
for . in x, y, z:
do_action("3.level")

```
1 message moved from Python

« first day (1953 days earlier)      last day (1625 days later) »