Atomic writes — how tempfile + os.replace prevent corrupted JSON

· Dev.to