in my code I export a csv file. Before the export happens, I need to modify some data. But while I do this, I\'m experiencing a race condition. While the id gets set correct