Skip to content

Configuration

This page describes how to configure checker with .checker.yml, .deadlines.yml and .task.yml files.

You can refer to the course-template repository for examples of configuration files.

.checker.yml

This file describes how the checker will operate - how to export files, how to run pipelines and so on.

TBA

No json schema available yet, but you can refer to the checker.configs.checker.CheckerConfig in checker repository.
Or course-template repository.

Warning

The structure section requires glob patterns to be valid and will apply the same patterns recursively to all subdirectories.
The moment it faces .task.yml file, it will stop and use the parameters from this file recursively.
No ** patterns are allowed.

Please refer to the plugins and pipelines sections for more information on how to configure pipelines.

Example

The simple .checker.yml file is:

# .checker.yml
version: 1

# can be overwritten in .task.yml for individual tasks
structure:
  # ignore patterns: exclude from export, overwrite during testing
  ignore_patterns: [".git", ".idea", ".vscode", "__pycache__", ".venv", ".*_cache", "*.pyc"]
  # public patterns: include in export, overwrite during testing
  public_patterns: ["*", ".gitlab-ci-students.yml", ".gitignore"]
  # private patterns: exclude from export, overwrite during testing
  private_patterns: [".*"]

# default values for all tasks, can be overwritten in .task.yml params:
default_parameters:
  run_testing: true
  timeout: 10  # in seconds

# settings for export command, uses .deadlines.yml and `params` and each task params (in .task.yml)
export:
  destination: https://gitlab.manytask.org/test/public-test-repo

# settings for Tester, uses .checker.yml and `params` and each task params (in .task.yml)
testing:
  search_plugins: ["tools/plugins"]

  # run once per repo
  global_pipeline:
    - ...
  # run once per task
  tasks_pipeline:
    - ...
    - ...
  # will run once per task only if task_pipeline NOT failed
  report_pipeline:
    - ...

.deadlines.yml

This file describes deadlines for tasks. It is used by checker export command to export only tasks that are started.
Additionally, it is used by checker validate to ensure integrity of the deadlines and local files.

No json schema available yet, but you can refer to the checker.configs.deadlines.DeadlinesConfig in checker repository.
Or course-template repository.

Example

The simple .deadlines.yml file is:

# .deadlines.yml
version: 1

settings:
  timezone: Europe/Moscow

  deadlines: hard  # hard/interpolate
  max_submissions: 10  # optional
  submission_penalty: 0.1  # optional

  task_url: https://example.com/$GROUP_NAME/$TASK_NAME  # optional

schedule:
  - group: 1.FirstGroup
    enabled: true
    start: 2020-01-01 18:00:00
    steps:
      0.5: 7d
    end: 13d 03:00:00
    tasks:
      - task: hello_world
        score: 10
        bonus: 0
        special: 1
      - task: sum_a_b
        score: 5
        bonus: 5
        special: 0
      - task: disabled_task
        enabled: false
        score: 5

  - group: 2.SecondGroup
    start: 2020-02-01 18:00:00
    steps:
      0.9: 2020-02-08 18:00:00
      0.1: 14d
    tasks:
      - task: factorial
        score: 20

  - group: 3.ThirdGroup
    start: 2020-03-01 18:00:00
    tasks:
      - task: palindrome
        score: 0
        special: 2
        url: https://example.com

  - group: 4.FourthGroup
    enabled: false
    start: 2020-04-01 18:00:00
    tasks: []

.task.yml

This optional file describes task parameters. In used by checker when running tasks_pipeline to override default parameters, pipeline or layout (public or private files).

No json schema available yet, but you can refer to the checker.configs.task.TaskConfig in checker repository.
Or course-template repository.

Example

# .task.yml
version: 1

structure:  # optional
  ignore_patterns: ["*.pyc"]
  public_patterns: ["custom_public_file.txt"]
  private_patterns: [".*", "custom_private_tests.py"]

parameters:  # optional
  run_testing: true
  timeout: 10  # in seconds

task_pipeline:  # optional
  ...

report_pipeline:  # optional
  ...