Skip to content

Commit 5b9de4a

Browse files
fix(server): blacklist local files (#609)
Close #589 #602
1 parent c8b077b commit 5b9de4a

File tree

1 file changed

+8
-0
lines changed

1 file changed

+8
-0
lines changed

server/text_generation_server/utils/convert.py

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -94,6 +94,14 @@ def convert_files(pt_files: List[Path], sf_files: List[Path], discard_names: Lis
9494
# We do this instead of using tqdm because we want to parse the logs with the launcher
9595

9696
for i, (pt_file, sf_file) in enumerate(zip(pt_files, sf_files)):
97+
# Skip blacklisted files
98+
if (
99+
"arguments" in pt_file.name
100+
or "args" in pt_file.name
101+
or "training" in pt_file.name
102+
):
103+
continue
104+
97105
start = datetime.datetime.now()
98106
convert_file(pt_file, sf_file, discard_names)
99107
elapsed = datetime.datetime.now() - start

0 commit comments

Comments
 (0)