runner
runner
¶
Validation runner that orchestrates all checks.
The ValidationRunner collects all registered checks, runs them against a configuration, and aggregates the results.
Classes¶
ValidationRunner
¶
Orchestrates validation checks against a configuration.
The runner collects issues from all checks, sorts them by severity, and provides summary information for reporting.
Initialize with a list of checks.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
checks
|
list[ValidationCheck] | None
|
List of validation checks to run. If None, uses default checks. |
None
|
Source code in src/marianne/validation/runner.py
Functions¶
add_check
¶
validate
¶
Run all validation checks against the configuration.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
config
|
JobConfig
|
Parsed JobConfig object |
required |
config_path
|
Path
|
Path to the config file |
required |
raw_yaml
|
str
|
Raw YAML text for line number extraction |
required |
Returns:
| Type | Description |
|---|---|
list[ValidationIssue]
|
List of all issues found, sorted by severity (errors first) |
Source code in src/marianne/validation/runner.py
get_exit_code
¶
Determine exit code based on issues found.
Returns:
| Name | Type | Description |
|---|---|---|
0 |
int
|
No errors (warnings/info OK) |
1 |
int
|
One or more ERROR-severity issues |
Source code in src/marianne/validation/runner.py
has_errors
¶
count_by_severity
¶
Count issues by severity level.
Source code in src/marianne/validation/runner.py
Functions¶
create_default_checks
¶
Create the default set of validation checks.
Returns all built-in checks in recommended execution order.