Skip to content
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

Grading batch rework #28

Merged
merged 8 commits into from
Nov 29, 2021
Merged

Conversation

alexstaeding
Copy link
Member

Adds some missing abstraction in the batch loading process.

Breaking changes

This PR makes several breaking changes in the grader and solution loading mechanisms. Solution jars are no longer separate from the grader jar.

Instead, the grader contains all (source) files from the grader and the solution together. To differentiate between grader and solution classes, there is a new grader-info.json (analogous to submission-info.json for submissions) that contains information as to which files are part of the grader, and which are part of the solution.

The format is as follows:

{
  "name": "example-grader",
  "assignmentIds": ["h03"],
  "sourceSets": [
    {
      "name": "grader",
      "files": [
        "h03\\H03_RubricProvider.java",
        "h03\\TutorTests.java"
      ]
    },
    {
      "name": "solution",
      "files": [
        "h03\\Main.java"
      ]
    }
  ]
}

New API

The following methods were added to RubricConfiguration:

  List<String> getFileNameSolutionOverrides();

  RubricConfiguration addFileNameSolutionOverride(String fileName);

  default RubricConfiguration addFileNameSolutionOverride(Class<?> clazz) {
    return addFileNameSolutionOverride(Type.getInternalName(clazz) + ".java");
  }

It is now possible to specify files that should be completely replaced in the submission from the solution.

@alexstaeding alexstaeding added the semver:major A major change breaking backwards compatibility label Nov 29, 2021
@alexstaeding alexstaeding added this to the v0.3 milestone Nov 29, 2021
@alexstaeding alexstaeding self-assigned this Nov 29, 2021
@alexstaeding alexstaeding merged commit c5e8681 into dev-0.3 Nov 29, 2021
@alexstaeding alexstaeding deleted the feature/0.3/grading-batch-rework branch October 25, 2022 20:57
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
semver:major A major change breaking backwards compatibility
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant