Skip to content

Commit ef62ef8

Browse files
authored
Merge pull request #3 from caoyicheng11/main
Fix resolve concurrency execution conflicts
2 parents 0b27ba5 + dba69f4 commit ef62ef8

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed

process_formula/normalize_formulas.py

+3-1
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,7 @@
11
# -*- encoding: utf-8 -*-
22
# @Author: SWHL
33
# @Contact: [email protected]
4+
import uuid
45
import argparse
56
import re
67
import subprocess
@@ -86,7 +87,8 @@ def write_txt(
8687
f.write(f"{value}\n")
8788

8889
def get_normalize_formulas(self, after_content, mode) -> List[str]:
89-
temp_file = self.root_dir / "tmp"
90+
temp_id = uuid.uuid4()
91+
temp_file = self.root_dir / f"tmp_{temp_id}"
9092
self.write_txt(temp_file, after_content)
9193

9294
out_path = Path(temp_file).with_suffix(".temp.out")

0 commit comments

Comments
 (0)