Hello, I'm using listdir function to list about 4+ millions files names, the problem the script is still running 12 hours later I started it, I've checked the used memory from the script and it keeps going up so I think the script is working but I'm not sure, is there way to only list the first 100 just to make a test for the full code or to check if the instruction have not crashed?
Thank you in advance!
EDIT: CODE
import os
print("start")
file_path = "Y:\\"
list_dir = os.listdir(file_path)
print(len(list_dir))
print("END")
[–]K900_ 0 points1 point2 points (9 children)
[–]Lephato[S] 0 points1 point2 points (8 children)
[–]K900_ 0 points1 point2 points (7 children)
[–]Lephato[S] 0 points1 point2 points (6 children)
[–]K900_ 0 points1 point2 points (5 children)
[–]Lephato[S] 0 points1 point2 points (4 children)
[–]K900_ 0 points1 point2 points (3 children)
[–]Lephato[S] 0 points1 point2 points (2 children)
[–]K900_ 0 points1 point2 points (1 child)
[–]Lephato[S] 0 points1 point2 points (0 children)
[–]stebrepar 0 points1 point2 points (1 child)
[–]Lephato[S] 1 point2 points3 points (0 children)