1 year ago

#320607

test-img

Miguel

Do I need FileLock to read a file that is being written by other batch of processes using file-locking?

I have a bunch of processes accessing and modifying a csv file from Python at the same time (safely doing so with FileLock). I access the file using the Pandas package.

I would like to launch another batch of processes which are going to access this same file (reading) but without modifying it. Can I access this file without using a locking system, and still have the first writing processes unaffected by this?

In case that it is okay to do this, will the reading of the file have to wait for a writing process to finish if it is locked?

I must note, in case that it is not clear, that I do not want the writing processes to be affected by the reading ones. However, the modifications done by the writing processes on the file are not relevant for the reading processes in my case, so I do not mind in which stage of writing they are.

python

file

multiprocessing

file-locking

filelock

0 Answers

Your Answer

Accepted video resources