Ben,
Thank you.
Caleb
--
http://mail.python.org/mailman/listinfo/python-list
Caleb Hattingh wrote:
> Your code works on some folders but not others. For example, it works
> on my /usr/lib/python2.4 (the example you gave), but on other folders
> it terminates early with StopIteration exception on the
> os.walk().next() step.
>
> I haven't really looked at this closely enou
Hi John
Your code works on some folders but not others. For example, it works
on my /usr/lib/python2.4 (the example you gave), but on other folders
it terminates early with StopIteration exception on the
os.walk().next() step.
I haven't really looked at this closely enough yet, but it looks as
Thanks John
I will use your code :) 30% improvement is not insignificant, and
that's what I was looking for.
I find the log function a little harder to read, but I guess that is a
limitation of me, not your code.
Caleb
--
http://mail.python.org/mailman/listinfo/python-list
Caleb Hattingh wrote:
> Hi everyone
>
> [Short version: I put a some code below: what changes can make it run
> faster?]
On my slow notebook, your code takes about 1.5 seconds to do my
C:\Python24 dir. With a few changes my code does it in about 1 second.
Here is my code:
import os, os.path,
Caleb Hattingh wrote:
> Unless you have a nice tool handy, calculating many folder sizes for
> clearing disk space can be a click-fest nightmare. Looking around, I
> found Baobab (gui tool); the "du" linux/unix command-line tool; the
> extremely impressive tkdu: http://unpythonic.net/jeff/tkdu/ ;
Hi everyone
[Short version: I put a some code below: what changes can make it run
faster?]
Unless you have a nice tool handy, calculating many folder sizes for
clearing disk space can be a click-fest nightmare. Looking around, I
found Baobab (gui tool); the "du" linux/unix command-line tool; th