Testing for file open

Michaell Taylor Michaell.Taylor at reis.com
Thu Jun 15 11:24:05 EDT 2000


Sorry, another newbie question.

I am writing a script (ScriptA) which writes to a file which could possibly
already be opened (either in read or write mode) by another python script
(ScriptB).

I would like for ScriptA to test the opened status of the file and if
already opened, delay writing for a second or two (at which point it should
be closed again).

Now for the complication - ScriptA and ScriptB will be running on different
machines and different OSs (NT and Linux) both accessing a file on a Samba
share.

Any ideas?

Thanks in advance.

Michaell





More information about the Python-list mailing list