From cea90dbda59e7721b7f386d8adb7652b380de212 Mon Sep 17 00:00:00 2001 From: Barrett Ruth Date: Tue, 4 Nov 2025 22:10:42 -0500 Subject: [PATCH] preliminary updates --- scrapers/atcoder.py | 9 +++++++++ scrapers/codechef.py | 8 ++++++++ 2 files changed, 17 insertions(+) diff --git a/scrapers/atcoder.py b/scrapers/atcoder.py index d46159c..7d266d0 100644 --- a/scrapers/atcoder.py +++ b/scrapers/atcoder.py @@ -314,16 +314,25 @@ class AtcoderScraper(BaseScraper): return data = await asyncio.to_thread(_scrape_problem_page_sync, category_id, slug) tests: list[TestCase] = data.get("tests", []) + + combined_input = "\n".join(t.input for t in tests) + combined_expected = "\n".join(t.expected for t in tests) + print( json.dumps( { "problem_id": letter, + "combined": { + "input": combined_input, + "expected": combined_expected, + }, "tests": [ {"input": t.input, "expected": t.expected} for t in tests ], "timeout_ms": data.get("timeout_ms", 0), "memory_mb": data.get("memory_mb", 0), "interactive": bool(data.get("interactive")), + "multi_test": False, } ), flush=True, diff --git a/scrapers/codechef.py b/scrapers/codechef.py index c2c768c..59efa01 100644 --- a/scrapers/codechef.py +++ b/scrapers/codechef.py @@ -231,14 +231,22 @@ class CodeChefScraper(BaseScraper): memory_mb = 256.0 interactive = False + combined_input = "\n".join(t.input for t in tests) + combined_expected = "\n".join(t.expected for t in tests) + return { "problem_id": problem_code, + "combined": { + "input": combined_input, + "expected": combined_expected, + }, "tests": [ {"input": t.input, "expected": t.expected} for t in tests ], "timeout_ms": timeout_ms, "memory_mb": memory_mb, "interactive": interactive, + "multi_test": False, } tasks = [run_one(problem_code) for problem_code in problems.keys()]