-
Notifications
You must be signed in to change notification settings - Fork 271
Add two features: the ability to view the first failed test case and to copy and paste code directly. #2696
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
|
GitGuardian id | GitGuardian status | Secret | Commit | Filename | |
---|---|---|---|---|---|
- | - | Generic Password | 88e7d2a | docker-compose.yml | View secret |
🛠 Guidelines to remediate hardcoded secrets
- Understand the implications of revoking this secret by investigating where it is used in your code.
- Replace and store your secret safely. Learn here the best practices.
- Revoke and rotate this secret.
- If possible, rewrite git history. Rewriting git history is not a trivial act. You might completely break other contributing developers' workflow and you risk accidentally deleting legitimate data.
To avoid such incidents in the future consider
- following these best practices for managing and storing secrets including API keys and other credentials
- install secret detection on pre-commit to catch secret before it leaves your machine and ease remediation.
🦉 GitGuardian detects secrets in your source code to help developers and security teams secure the modern development process. You are seeing this because you or someone else with access to this repository has authorized GitGuardian to scan your pull request.
General comment: this PR contains a lot of unrelated code changes including passwords that you probably should change. As for the additional features: I don't think we should incorporate sharing results with contestants in main and it's probably ok to keep this functionality in your fork. Also note that with parallel judging you are exposing more to contestants than you likely want to expose. The source code editor behind a toggle sounds like a reasonable feature. We might switch at a later point from Ace editor to Monaco (#2689) but this shouldn't make it more complex. Can you please try to extract your changes to add this functionality in a separate PR? |
Alright, I will submit a separate PR for the source code editor later. Thank you! |
Motivation:
I have served as a teaching assistant for several courses, such as Data Structures and Programming, where DOMjudge was used in class. For beginners, it's often the case that a simple mistake or a small oversight of edge cases can lead to many "wrong answer" results. I believe this can be quite frustrating for those just learning to program. On platforms like Codeforces, you can see which test case your solution failed on, and on LeetCode, when a solution is not accepted (non-AC), the incorrect test case is often provided. Therefore, I believe these two features would be very useful for educational purposes.
As for the process of uploading code as files, I often find it a bit inconvenient. In online judges like Codeforces and Luogu, there are features allowing users to paste code directly. I believe this is a very convenient feature to have.
Implementation:
These features can all be toggled on or off in the configuration settings.
Most of them are adapted from the jury interface.
Teams can view the status of each test case from their interface.

For non-correct and non-compile error submissions, the first failed test case will be displayed.
A navigation tab is provided for users to choose between uploading a file or pasting code.