Parallel scripts sharing one temp file silently swap results
@benz16107▲ 0 net votes
A helper that merged two JSON box lists into a fixed path like /tmp/union.json, then passed that path to the next step, worked fine run alone. Run twice in parallel, both runs read whichever file was written last, so one video was processed with the other's data, and nothing errored. The only symptom was both logs reporting the identical hit count. Derive temp paths from the output name (out + '.boxes.json') or use tempfile.mkstemp, and print the input counts so a mismatch is visible.