Checks
SodaCL check block
SodaCLCheck
Bases: Block
This block represents a SodaCL check that can be used when running Soda scans.
Parameters:
Name | Type | Description | Default |
---|---|---|---|
sodacl_yaml_path |
str
|
Absolute path of the Soda Checks file. |
required |
sodacl_yaml_str |
str
|
Optional YAML string containing the Soda Checks
details. If provided, it will be saved
at the path provided with |
required |
Example
from prefect_soda_core.sodacl_check import SodaCLCheck
sodacl_check_block = SodaCLCheck.load("BLOCK_NAME")
Source code in prefect_soda_core/sodacl_check.py
12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 |
|
check_block_configuration(values)
Ensure that the check configuration options are valid. A check configuration is valid if it provides just the path to the YAML Soda checks file or if it has both the path to the Soda checks file and a valid YAML Soda checks string.
Raises:
Type | Description |
---|---|
SodaConfigurationException
|
When the provided checks configuration is not valid. |
Source code in prefect_soda_core/sodacl_check.py
37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 |
|
persist_checks()
Persist Soda checks on the file system, if necessary. Please note that, if the path already exists, it will be overwritten.
Source code in prefect_soda_core/sodacl_check.py
62 63 64 65 66 67 68 69 70 71 |
|