memory management

Chris Angelico rosuav at gmail.com
Mon Nov 7 16:40:56 EST 2011


On Tue, Nov 8, 2011 at 6:43 AM, Juan Declet-Barreto
<Juan.Declet-Barreto at mesaaz.gov> wrote:
>
> I have a script that traverses a file structure using os.walk and adds directory names to a list. It works for a small number of directories, but when I set it loose on a directory with thousands of dirs/subdirs, it crashes the DOS session and also the Python shell (when I run it from the shell).

This seems a little unusual - it crashes more than its own process? If
you use Start... Run and type in "cmd" (or use the "Command Prompt"
icon, whereever that is), and invoke Python from there, it crashes cmd
as well as Python? If so, I'd be suspecting either some really weird
bug in the Python interpreter (try upgrading to 2.7), or a hardware
fault in your computer (try running MemTest or running it on a
different computer).

ChrisA



More information about the Python-list mailing list