From 2a6d11511d23ae5dbbc0e64181d3774b6a84a5af Mon Sep 17 00:00:00 2001 From: Flowtter Date: Sun, 28 Jan 2024 17:24:47 +0100 Subject: [PATCH] fix: Requirements.txt and duplicate usernames --- crispy-api/api/tools/setup.py | 3 ++- crispy-api/requirements.txt | 1 + crispy-api/tests/tools/setup.py | 2 -- 3 files changed, 3 insertions(+), 3 deletions(-) diff --git a/crispy-api/api/tools/setup.py b/crispy-api/api/tools/setup.py index b44e3d5..a515594 100644 --- a/crispy-api/api/tools/setup.py +++ b/crispy-api/api/tools/setup.py @@ -59,7 +59,8 @@ def handle_the_finals( for username, count in usernames_histogram.items(): if count > 2: - usernames.append(username) + if username not in usernames: + usernames.append(username) for ch in ("_", " ", ".", "-"): split_username = username.split(ch) diff --git a/crispy-api/requirements.txt b/crispy-api/requirements.txt index d761250..01093ea 100644 --- a/crispy-api/requirements.txt +++ b/crispy-api/requirements.txt @@ -20,3 +20,4 @@ progressbar2==4.0.0 scipy==1.8.0 pydub==0.25.1 montydb==2.4.0 +easyocr==1.7.1 diff --git a/crispy-api/tests/tools/setup.py b/crispy-api/tests/tools/setup.py index de76ddb..d805a38 100644 --- a/crispy-api/tests/tools/setup.py +++ b/crispy-api/tests/tools/setup.py @@ -102,10 +102,8 @@ async def test_handle_highlights_the_finals(tmp_path): "_raynox", "heximius", "raynox", - "raynox", "sxi", "sxr", - "sxr", "sxr_", ]