fix(diff): bugs on diff stdin and numerics #16

Merged
张泊明518370910136 merged 22 commits from fix/diff into master 2025-05-24 02:45:39 +08:00
Showing only changes of commit 044d0f0d41 - Show all commits

View File

@ -1,4 +1,3 @@
import os
import re
import shlex
from functools import partial
@ -256,7 +255,7 @@ def get_testcases(
) -> Set[str]: # basedir here should be task_conf.root / task_conf.path
testcases = set()
for testcases_path in (task_root / task_path).parent.glob("**/*.in"):
if not os.path.exists(str(testcases_path).removesuffix(".in") + ".out"):
if not testcases_path.with_suffix(".out").exists():
logger.warning(f"Testcase {testcases_path} has no corresponding .out file")
jon-lee marked this conversation as resolved

if not testcases_path.with_suffix(".out").exists():

`if not testcases_path.with_suffix(".out").exists():`

done

done
continue
testcases.add(