Re: Fwd: is file open in system ? - other than lsof

2008-04-18 Thread A.T.Hofkamp
On 2008-04-17, bvidinli <[EMAIL PROTECTED]> wrote: > is there another way, any python command sequence that i can check if > a file is open at the time of "before i process file" > > i am not interested in " the file may be written after i access it.." > the important point is " the time at i first

Fwd: is file open in system ? - other than lsof

2008-04-18 Thread bvidinli
the idea of eg does not work for me because, what i do: get list of files, check 1st file open ? process 1st file, (this may take several seconds... ) check 2nd file open? i have to check it here, because 2nd file may be opened while i process file 1 process 2nd file, (this may take several seco

Fwd: is file open in system ? - other than lsof

2008-04-17 Thread bvidinli
Here is (hope) complete info for my question: i use linux/unix i use python 2.3 my subject is a single file at a time. but i have to check thousands of files in a loop. so, since there is thousands of files to process, i dont want to use like os.system('lsof filename') because lsof is slow regardi