Solution runner can exceed the configured timeout and keep CI running
Maintainer antworten meist innerhalb von 1 Tag
Bewertung
- Schwierigkeit
- 4/5
- Geschätzter Aufwand
- 3-5 Tage
- Anfängerfreundlichkeit
- 48/100
Rechercherichtung
Start by reading run.py and the GitHub Actions workflow; trace how the per-test timeout is applied and how compilation is launched. Run the existing test suite and inspect how the runner handles timed-out processes. Done means compilation and total execution have separate limits, spawned processes are cleaned up, and the workflow has an appropriate job timeout.
Vom Indexierungsmodell aus dem Issue-Text verfasst.
Beschreibung
I noticed that the solution runner doesn't properly limit how long a submitted solution can run.
The configured timeout is applied separately to each test case rather than to the solution's total execution time. Compilation also doesn't appear to have any timeout.
For example, I tested four cases that each took around 0.35 seconds. All four passed with a configured timeout of just 1 second, even though the total execution took approximately 1.55 seconds.
With the current behavior, 100 test cases and a 10-second timeout could potentially keep a solution running for around 1,000 seconds. A compilation process that hangs could also block the runner indefinitely.
I expected the runner to enforce an overall execution limit so that a submitted solution couldn't occupy CI resources for much longer than intended.
Looking through run.py, the timeout is applied inside the loop that executes individual test cases, while the compilation step has no timeout. The GitHub Actions workflow also doesn't define a job-level timeout.
This could become a bigger problem with submissions that run slowly, generate excessive output, or start additional processes.
It would be useful to enforce separate compilation and overall execution limits, along with proper cleanup of spawned processes and safeguards against excessive resource usage.
- Vorherrschende Sprache
- Python
- Sterne
- 1
- Forks
- 6
- Ø Merge
- 12 Std. 42 Min.
- Gemergte PRs (30 T.)
- 10
Entwicklungsumgebung
- Kein Dockerfile und keine Docker-Compose-Datei
- Hat eine Pull-Request-Vorlage
- Kein Beitragsleitfaden
Erste Schritte
- Lesen Sie das ganze Issue und danach den Beitragsleitfaden des Projekts.
- Schreiben Sie ins Issue, dass Sie es übernehmen — das erspart doppelte Arbeit.
- Forken Sie das Repository und arbeiten Sie in einem Branch.
- Öffnen Sie einen Pull Request, der die Issue-Nummer nennt.
Mehr aus techcsispit/code-corner
-
prime/solution.java doesn't compile: public class PrimeCheck in solution.java, README requires Solution.java with a Solution classEvtl. vergeben @tanujb03 hat das vor 1 Tag übernommen. Offen
Schwierigkeit 1/5 Unter einer Stunde Anfängerfreundlichkeit 82/100
techcsispit/code-corner#35 ·
Maintainer antworten meist innerhalb von 1 Tag
-
run.py: Python solutions are skipped on Windows when run via python instead of python3Evtl. vergeben @tanujb03 hat das vor 1 Tag übernommen. Offenbug good first issue
Schwierigkeit 1/5 Unter einer Stunde Anfängerfreundlichkeit 15/100
techcsispit/code-corner#29 ·
Maintainer antworten meist innerhalb von 1 Tag
-
fibonacci/solution.c: prints negative numbers for n of 47 or more (F(90) prints -1581614984)Evtl. vergeben @tanujb03 hat das vor 1 Tag übernommen. Offenbug good first issue
Schwierigkeit 2/5 1-3 Stunden Anfängerfreundlichkeit 25/100
techcsispit/code-corner#27 ·
Maintainer antworten meist innerhalb von 1 Tag
-
binary-search/Solution.java: prints -1 when the target is the last element (`9 1 3 5 7 9`) or in a 1-element list (`5 5`)Evtl. vergeben @tanujb03 hat das vor 1 Tag übernommen. Offenbug good first issue
Schwierigkeit 2/5 1-3 Stunden Anfängerfreundlichkeit 22/100
techcsispit/code-corner#26 ·
Maintainer antworten meist innerhalb von 1 Tag
-
roman-numerals/solution.go: 4 prints IIII and 1994 prints MDCCCCLXXXXIIII (no subtractive forms)Evtl. vergeben @tanujb03 hat das vor 1 Tag übernommen. Offenbug good first issue
Schwierigkeit 2/5 1-3 Stunden Anfängerfreundlichkeit 25/100
techcsispit/code-corner#25 ·
Maintainer antworten meist innerhalb von 1 Tag
Alle Issues in techcsispit/code-corner
Ähnliche Issues
-
Schwierigkeit 1/5 Unter einer Stunde Anfängerfreundlichkeit 83/100
PedestrianDynamics/pyFDS-Evac#766 ·
Maintainer antworten meist innerhalb von 1 Tag
-
Schwierigkeit 1/5 1-3 Stunden Anfängerfreundlichkeit 91/100
alchaincyf/nuwa-skill#86 ·
-
Schwierigkeit 2/5 1-3 Stunden Anfängerfreundlichkeit 76/100
Maintainer antworten meist innerhalb von 2 Tagen
-
Docs Needs Triage
Schwierigkeit 1/5 Unter einer Stunde Anfängerfreundlichkeit 88/100
pandas-dev/pandas#71055 ·
Maintainer antworten meist innerhalb von 1 Tag
-
[Bug]: graphify reads files that git's global ignore file hidesEvtl. vergeben @smngvlkz hat das heute übernommen. Offen
Schwierigkeit 2/5 1-3 Stunden Anfängerfreundlichkeit 72/100
Graphify-Labs/graphify#4335 · 1 Kommentar ·
Maintainer antworten meist innerhalb von 1 Tag