Skip to content

Add more warnings about score ranges (and reject_score) - #484

Open
gkreitz wants to merge 4 commits into
Kattis:masterfrom
gkreitz:439_compute_score_range
Open

Add more warnings about score ranges (and reject_score)#484
gkreitz wants to merge 4 commits into
Kattis:masterfrom
gkreitz:439_compute_score_range

Conversation

@gkreitz

@gkreitz gkreitz commented Sep 1, 2026

Copy link
Copy Markdown
Contributor

In these new checks, we compute max scores for test data groups based on the configuration of their children, and add several new warnings:

  • If the range can be narrowed (e.g,. 10 points per test case, 7 test cases, but your range says 0 100)
  • If no range was specified, but we can compute one
  • If no range is specified on the root node (where you basically always want to specify something)
  • If the root node has a negative minimum (which is almost always a mistake)

I decided not to add warnings if the computed range is larger than the declared range (e.g., 11 test cases worth 10 each, but the range says 0 100). This should be caught by out-of-bounds checks when running submissions. Happy to take opinions on if we want to check it statically here too.

Note that these checks all disappear when a custom grader is used (for obvious reasons). And if custom scoring is used, we can't make any assumptions regarding what each test case is worth, so the checks are less likely to catch stuff.

I also added an explicit warning for using reject_score. It's been removed in the new format. I cannot think of a good use case, and it's always the default 0 in all of the problems ever installed on Kattis.

Fixes #439

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Compute score bounds based on grading conf and warn about discrepancies

1 participant