Skip to content

Commit fab5899

Browse files
committed
check uuids
1 parent ccc23b9 commit fab5899

File tree

1 file changed

+9
-0
lines changed

1 file changed

+9
-0
lines changed

bin/tools.py

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1032,6 +1032,15 @@ def run_parsed_arguments(args):
10321032
# Get problem_paths and cd to contest
10331033
problems, level, contest, tmpdir = get_problems()
10341034

1035+
# Check non unique uuid
1036+
# TODO: check this even more globally?
1037+
uuids: dict[str, Problem] = {}
1038+
for p in problems:
1039+
if p.settings.uuid in uuids:
1040+
warn(f"{p.name} has the same uuid as {uuids[p.settings.uuid].name}")
1041+
else:
1042+
uuids[p.settings.uuid] = p
1043+
10351044
# Check for incompatible actions at the problem/problemset level.
10361045
if level != "problem":
10371046
if action == "test":

0 commit comments

Comments
 (0)