From 3d1a52d8603954722cae6112660218e6d1a5c3c6 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Signe=20Kirk=20Br=C3=B8db=C3=A6k?= Date: Mon, 20 Oct 2025 16:16:32 +0200 Subject: [PATCH 1/4] refactor: :truck: rename `Exclude` to `Exclusion` And update arguments and docstrings to match. --- _quarto.yml | 2 +- docs/design/interface.qmd | 14 ++--- docs/guide/config.qmd | 22 ++++---- src/check_datapackage/__init__.py | 4 +- src/check_datapackage/check.py | 2 +- src/check_datapackage/config.py | 15 +++--- src/check_datapackage/exclude.py | 40 +++++++------- tests/test_check.py | 16 +++--- tests/test_exclude.py | 88 ++++++++++++++++--------------- 9 files changed, 107 insertions(+), 96 deletions(-) diff --git a/_quarto.yml b/_quarto.yml index 8946a702..217d5b2d 100644 --- a/_quarto.yml +++ b/_quarto.yml @@ -69,7 +69,7 @@ quartodoc: - name: read_json - name: Config - name: CustomCheck - - name: Exclude + - name: Exclusion - name: Issue - name: example_package_properties - name: example_resource_properties diff --git a/docs/design/interface.qmd b/docs/design/interface.qmd index ea78faa5..9bd74a8d 100644 --- a/docs/design/interface.qmd +++ b/docs/design/interface.qmd @@ -126,11 +126,13 @@ function. See the help documentation with `help(Config)` for more details. -### {{< var wip >}} `Exclude` +### {{< var wip >}} `Exclusion` -A subitem of `Config` for expressing checks to ignore. +A subitem of `Config` that expresses checks to exclude. This can be +useful if you want to exclude (or skip) certain checks from the Data +Package standard that are not relevant to your use case. -See the help documentation with `help(Exclude)` for more details. +See the help documentation with `help(Exclusion)` for more details. #### {{< var wip >}} `CustomCheck` @@ -164,7 +166,7 @@ flowchart TD config[/Config/] custom_check[/CustomCheck/] - exclude[/Exclude/] + exclusion[/Exclusion/] check["check()"] issues[/"list[Issue]"/] @@ -173,8 +175,8 @@ flowchart TD descriptor_file --> read_json --> descriptor config_file --> read_config --> config - custom_check & exclude --> config - custom_check & exclude -.-> config_file + custom_check & exclusion --> config + custom_check & exclusion -.-> config_file descriptor & config --> check --> issues --> explain --> messages ``` diff --git a/docs/guide/config.qmd b/docs/guide/config.qmd index 20bd7e93..644e4749 100644 --- a/docs/guide/config.qmd +++ b/docs/guide/config.qmd @@ -9,7 +9,7 @@ on the descriptor. The following configuration options are available: - `version`: The version of Data Package standard to check against. Defaults to `v2`. -- `exclude`: The list of checks to exclude. +- `exclusions`: A list of checks to exclude. - `custom_checks`: The list of custom checks to run in addition to the checks defined in the standard. - `strict`: Whether to run recommended checks in addition to required @@ -23,42 +23,42 @@ to. The Data Package standard defines a range of check types (e.g., `required` or `pattern`) and it is also possible to create your own. For example, to exclude checks flagging missing fields, you would exclude -the `required` check by defining an `Exclude` object with this `type`: +the `required` check by defining an `Exclusion` object with this `type`: ```{python} from textwrap import dedent import check_datapackage as cdp -exclude_required = cdp.Exclude(type="required") +exclusion_required = cdp.Exclusion(type="required") ``` To exclude checks of a specific field or fields, you can use a [JSON path](https://en.wikipedia.org/wiki/JSONPath) in the `jsonpath` -attribute of an `Exclude` object. For example, you can exclude all +attribute of an `Exclusion` object. For example, you can exclude all checks on the `name` field of the Data Package descriptor by writing: ```{python} -exclude_name = cdp.Exclude(jsonpath="$.name") +exclusion_name = cdp.Exclusion(jsonpath="$.name") ``` Or you can use the wildcard JSON path selector to exclude checks on the `path` field of **all** Data Resource descriptors: ```{python} -exclude_path = cdp.Exclude(jsonpath="$.resources[*].path") +exclusion_path = cdp.Exclusion(jsonpath="$.resources[*].path") ``` The `type` and `jsonpath` arguments can also be combined: ```{python} -exclude_desc_required = cdp.Exclude(type="required", jsonpath="$.resources[*].description") +exclusion_desc_required = cdp.Exclusion(type="required", jsonpath="$.resources[*].description") ``` -This would exclude required checks on the `description` field of Data +This will exclude required checks on the `description` field of Data Resource descriptors. -To make the `check()` function aware of your exclusions, you add them to -the `Config` object passed to the function: +To apply your exclusions when running the `check()`, you add them to +the `Config` object passed to the `check()` function: ```{python} package_descriptor = { @@ -77,7 +77,7 @@ package_descriptor = { ], } -config = cdp.Config(exclude=[exclude_required, exclude_name, exclude_path]) +config = cdp.Config(exclusions=[exclusion_required, exclusion_name, exclusion_path]) cdp.check(descriptor=package_descriptor, config=config) ``` diff --git a/src/check_datapackage/__init__.py b/src/check_datapackage/__init__.py index cb5ca414..4888dca1 100644 --- a/src/check_datapackage/__init__.py +++ b/src/check_datapackage/__init__.py @@ -4,13 +4,13 @@ from .config import Config from .custom_check import CustomCheck from .examples import example_package_properties, example_resource_properties -from .exclude import Exclude +from .exclude import Exclusion from .issue import Issue from .read_json import read_json __all__ = [ "Config", - "Exclude", + "Exclusion", "Issue", "CustomCheck", "example_package_properties", diff --git a/src/check_datapackage/check.py b/src/check_datapackage/check.py index a56effb2..51b63b7a 100644 --- a/src/check_datapackage/check.py +++ b/src/check_datapackage/check.py @@ -44,7 +44,7 @@ class for more details, especially about the default values. issues = _check_object_against_json_schema(descriptor, schema) issues += apply_custom_checks(config.custom_checks, descriptor) - issues = exclude(issues, config.exclude, descriptor) + issues = exclude(issues, config.exclusions, descriptor) return sorted(set(issues)) diff --git a/src/check_datapackage/config.py b/src/check_datapackage/config.py index e32c51d2..7e496f5f 100644 --- a/src/check_datapackage/config.py +++ b/src/check_datapackage/config.py @@ -2,7 +2,7 @@ from typing import Literal from check_datapackage.custom_check import CustomCheck -from check_datapackage.exclude import Exclude +from check_datapackage.exclude import Exclusion @dataclass @@ -10,8 +10,8 @@ class Config: """Configuration for checking a Data Package descriptor. Attributes: - exclude (list[Exclude]): Any issues matching any of these exclusions will be - ignored (i.e., removed from the output of the check function). + exclusions (list[Exclusion]): Any issues matching any of Exclusion objects will + be excluded (i.e., removed from the output of the check function). custom_checks (list[CustomCheck]): Custom checks listed here will be done in addition to checks defined in the Data Package standard. strict (bool): Whether to run recommended as well as required checks. If @@ -23,18 +23,21 @@ class Config: ```{python} import check_datapackage as cdp - exclude_required = cdp.Exclude(type="required") + exclusion_required = cdp.Exclusion(type="required") license_check = cdp.CustomCheck( type="only-mit", jsonpath="$.licenses[*].name", message="Data Packages may only be licensed under MIT.", check=lambda license_name: license_name == "mit", ) - config = cdp.Config(exclude=[exclude_required], custom_checks=[license_check]) + config = cdp.Config( + exclusions=[exclusion_required], + custom_checks=[license_check], + ) ``` """ - exclude: list[Exclude] = field(default_factory=list) + exclusions: list[Exclusion] = field(default_factory=list) custom_checks: list[CustomCheck] = field(default_factory=list) strict: bool = False version: Literal["v1", "v2"] = "v2" diff --git a/src/check_datapackage/exclude.py b/src/check_datapackage/exclude.py index d76d0e2d..0288d896 100644 --- a/src/check_datapackage/exclude.py +++ b/src/check_datapackage/exclude.py @@ -11,12 +11,12 @@ @dataclass -class Exclude: - r"""Exclude issues when checking a Data Package descriptor. +class Exclusion: + r"""A check to be excluded when checking properties. - When you use both `jsonpath` and `type` in the same `Exclude`, only issues that - match *both* will be excluded, meaning it is an `AND` logic. If you want `OR` logic, - use multiple `Exclude` objects in the `Config`. + When you use both `jsonpath` and `type` in the same `Exclusion` object, only issues + that match *both* will be excluded, meaning it is an `AND` logic. If you want `OR` + logic, use multiple `Exclusion` objects in the `Config`. Attributes: jsonpath (Optional[str]): [JSON path](https://jg-rp.github.io/python-jsonpath/syntax/) @@ -30,9 +30,9 @@ class Exclude: ```{python} import check_datapackage as cdp - exclude_required = cdp.Exclude(type="required") - exclude_name = cdp.Exclude(jsonpath="$.name") - exclude_desc_required = cdp.Exclude( + exclusion_required = cdp.Exclusion(type="required") + exclusion_name = cdp.Exclusion(jsonpath="$.name") + exclusion_desc_required = cdp.Exclusion( type="required", jsonpath="$.resources[*].description" ) @@ -44,36 +44,38 @@ class Exclude: def exclude( - issues: list[Issue], excludes: list[Exclude], descriptor: dict[str, Any] + issues: list[Issue], exclusions: list[Exclusion], descriptor: dict[str, Any] ) -> list[Issue]: - """Exclude issues based on the provided configuration settings.""" + """Exclude issues defined by Exclusion objects.""" return _filter( issues, - lambda issue: not _get_any_matches(issue, excludes, descriptor), + lambda issue: not _get_any_matches(issue, exclusions, descriptor), ) def _get_any_matches( - issue: Issue, excludes: list[Exclude], descriptor: dict[str, Any] + issue: Issue, exclusions: list[Exclusion], descriptor: dict[str, Any] ) -> bool: matches: list[bool] = _map( - excludes, lambda exclude: _get_matches(issue, exclude, descriptor) + exclusions, lambda exclusion: _get_matches(issue, exclusion, descriptor) ) return any(matches) -def _get_matches(issue: Issue, exclude: Exclude, descriptor: dict[str, Any]) -> bool: +def _get_matches( + issue: Issue, exclusion: Exclusion, descriptor: dict[str, Any] +) -> bool: matches: list[bool] = [] - both_none = exclude.jsonpath is None and exclude.type is None + both_none = exclusion.jsonpath is None and exclusion.type is None if both_none: return False - if exclude.jsonpath: - matches.append(_same_jsonpath(issue, exclude.jsonpath, descriptor)) + if exclusion.jsonpath: + matches.append(_same_jsonpath(issue, exclusion.jsonpath, descriptor)) - if exclude.type: - matches.append(_same_type(issue, exclude.type)) + if exclusion.type: + matches.append(_same_type(issue, exclusion.type)) return all(matches) diff --git a/tests/test_check.py b/tests/test_check.py index bc37e72f..ac2da2ab 100644 --- a/tests/test_check.py +++ b/tests/test_check.py @@ -6,7 +6,7 @@ example_package_properties, example_resource_properties, ) -from check_datapackage.exclude import Exclude +from check_datapackage.exclude import Exclusion from tests.test_custom_check import lowercase_check # Without recommendations @@ -142,12 +142,13 @@ def test_fails_properties_violating_recommendations(): } -def test_exclude_not_excluding_custom_check(): +def test_exclusion_does_not_exclude_custom_check(): + """Exclusion should not exclude custom check if types do not match.""" properties = example_package_properties() properties["name"] = "ALLCAPS" del properties["resources"] - exclude_required = Exclude(type="required") - config = Config(custom_checks=[lowercase_check], exclude=[exclude_required]) + exclusion_required = Exclusion(type="required") + config = Config(custom_checks=[lowercase_check], exclusions=[exclusion_required]) issues = check(properties, config=config) @@ -155,11 +156,12 @@ def test_exclude_not_excluding_custom_check(): assert issues[0].type == "lowercase" -def test_exclude_excluding_custom_check(): +def test_exclusion_does_exclude_custom_check(): + """Exclusion should exclude custom check if types match.""" properties = example_package_properties() properties["name"] = "ALLCAPS" - exclude_lowercase = Exclude(type=lowercase_check.type) - config = Config(custom_checks=[lowercase_check], exclude=[exclude_lowercase]) + exclusion_lowercase = Exclusion(type=lowercase_check.type) + config = Config(custom_checks=[lowercase_check], exclusions=[exclusion_lowercase]) issues = check(properties, config=config) diff --git a/tests/test_exclude.py b/tests/test_exclude.py index bf898979..f8b8a011 100644 --- a/tests/test_exclude.py +++ b/tests/test_exclude.py @@ -5,76 +5,76 @@ from check_datapackage.check import check from check_datapackage.config import Config from check_datapackage.examples import example_package_properties -from check_datapackage.exclude import Exclude +from check_datapackage.exclude import Exclusion -def test_exclude_none_type(): +def test_exclusion_none_type_and_jsonpath(): properties: dict[str, Any] = { "name": "a name", "resources": [{"name": "a name", "path": "data.csv"}], "contributors": [{"path": "/a/bad/path"}], } - exclude = [Exclude()] - config = Config(exclude=exclude) + exclusion = [Exclusion()] + config = Config(exclusions=exclusion) issues = check(properties, config=config) assert len(issues) == 1 -def test_exclude_required_type(): - """Exclude type with the required value.""" +def test_exclusion_required_type(): + """Exclusion by required type.""" properties = {"name": "a name with spaces"} - exclude = [Exclude(type="required")] - config = Config(exclude=exclude) + exclusion = [Exclusion(type="required")] + config = Config(exclusions=exclusion) issues = check(properties, config=config) assert len(issues) == 0 -def test_exclude_format_type(): - """Exclude type with the format value.""" +def test_exclusion_format_type(): + """Exclusion by format type.""" # created must match a date format properties = {"created": "20240614"} - exclude = [Exclude(type="format")] - config = Config(exclude=exclude) + exclusion = [Exclusion(type="format")] + config = Config(exclusions=exclusion) issues = check(properties, config=config) # One issue: missing resources assert len(issues) == 1 -def test_exclude_pattern_type(): - """Exclude types with the pattern value.""" +def test_exclusion_pattern_type(): + """Exclusion by pattern type.""" properties: dict[str, Any] = { "name": "a name", "resources": [{"name": "a name", "path": "data.csv"}], "contributors": [{"path": "/a/bad/path"}], } - exclude = [Exclude(type="pattern")] - config = Config(exclude=exclude) + exclusion = [Exclusion(type="pattern")] + config = Config(exclusions=exclusion) issues = check(properties, config=config) assert len(issues) == 0 -def test_exclude_multiple_types(): - """Exclude by many types.""" +def test_exclusions_multiple_types(): + """Exclusions by multiple types.""" properties: dict[str, Any] = { "name": "a name", "created": "20240614", "contributors": [{"path": "/a/bad/path"}], } - exclude = [ - Exclude(type="required"), - Exclude(type="pattern"), - Exclude(type="format"), + exclusions = [ + Exclusion(type="required"), + Exclusion(type="pattern"), + Exclusion(type="format"), ] - config = Config(exclude=exclude) + config = Config(exclusions=exclusions) issues = check(properties, config=config) assert len(issues) == 0 @@ -101,7 +101,7 @@ def test_exclude_multiple_types(): ("$.resources[0].path", 2), ], ) -def test_exclude_jsonpath(jsonpath: str, num_issues: int) -> None: +def test_exclusion_jsonpaths(jsonpath: str, num_issues: int) -> None: properties = example_package_properties() # Total 3 issues properties["created"] = "20240614" @@ -109,60 +109,60 @@ def test_exclude_jsonpath(jsonpath: str, num_issues: int) -> None: properties["resources"][0]["path"] = "/a/bad/path" properties.update({"contributors": [{"path": "/a/bad/path"}]}) - exclude = [Exclude(jsonpath=jsonpath)] - config = Config(exclude=exclude) + exclusion = [Exclusion(jsonpath=jsonpath)] + config = Config(exclusions=exclusion) issues = check(properties, config=config) assert len(issues) == num_issues -def test_exclude_jsonpath_multiple(): +def test_exclusion_multiple_jsonpaths(): properties = example_package_properties() properties["created"] = "20240614" properties.update({"contributors": [{"path": "/a/bad/path"}]}) - exclude = [ - Exclude(jsonpath="$.contributors[0].path"), - Exclude(jsonpath="$.created"), + exclusions = [ + Exclusion(jsonpath="$.contributors[0].path"), + Exclusion(jsonpath="$.created"), ] - config = Config(exclude=exclude) + config = Config(exclusions=exclusions) issues = check(properties, config=config) assert len(issues) == 0 -def test_exclude_jsonpath_and_type(): +def test_exclusion_jsonpath_and_type(): properties = example_package_properties() properties["contributors"] = [{"path": "/a/bad/path"}, {"path": "/a/bad/path"}] - exclude = [ - Exclude(jsonpath="$.contributors[0].path", type="pattern"), + exclusions = [ + Exclusion(jsonpath="$.contributors[0].path", type="pattern"), ] - config = Config(exclude=exclude) + config = Config(exclusions=exclusions) issues = check(properties, config=config) assert len(issues) == 1 -def test_exclude_jsonpath_and_type_non_overlapping(): +def test_exclusion_jsonpath_and_type_non_overlapping(): properties = example_package_properties() # There should be two issues properties["created"] = "20240614" properties.update({"contributors": [{"path": "/a/bad/path"}]}) - exclude = [ - Exclude(jsonpath="$.contributors[0].path"), - Exclude(type="pattern"), + exclusions = [ + Exclusion(jsonpath="$.contributors[0].path"), + Exclusion(type="pattern"), ] - config = Config(exclude=exclude) + config = Config(exclusions=exclusions) issues = check(properties, config=config) # For the created field assert len(issues) == 1 -def test_exclude_jsonpath_resources(): - """Exclude by jsonpath for resources.""" +def test_exclusion_jsonpath_resources(): + """Exclusion by jsonpath for resources.""" properties: dict[str, Any] = { "name": "woolly-dormice", "title": "Hibernation Physiology of the Woolly Dormouse: A Scoping Review.", @@ -173,5 +173,7 @@ def test_exclude_jsonpath_resources(): "licenses": [{"name": "odc-pddl"}], "resources": "this is a string", # should be an array } - issues = check(properties, config=Config(exclude=[Exclude(jsonpath="$.resources")])) + issues = check( + properties, config=Config(exclusions=[Exclusion(jsonpath="$.resources")]) + ) assert len(issues) == 0 From 8808ccef650754b4c1d133654456d77a0056e151 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Signe=20Kirk=20Br=C3=B8db=C3=A6k?= Date: Mon, 20 Oct 2025 16:23:24 +0200 Subject: [PATCH 2/4] refactor: :truck: rename module from `exclude` to `exclusion` --- src/check_datapackage/__init__.py | 2 +- src/check_datapackage/check.py | 2 +- src/check_datapackage/config.py | 2 +- src/check_datapackage/{exclude.py => exclusion.py} | 0 tests/test_check.py | 2 +- tests/{test_exclude.py => test_exclusion.py} | 2 +- 6 files changed, 5 insertions(+), 5 deletions(-) rename src/check_datapackage/{exclude.py => exclusion.py} (100%) rename tests/{test_exclude.py => test_exclusion.py} (99%) diff --git a/src/check_datapackage/__init__.py b/src/check_datapackage/__init__.py index 4888dca1..8239c552 100644 --- a/src/check_datapackage/__init__.py +++ b/src/check_datapackage/__init__.py @@ -4,7 +4,7 @@ from .config import Config from .custom_check import CustomCheck from .examples import example_package_properties, example_resource_properties -from .exclude import Exclusion +from .exclusion import Exclusion from .issue import Issue from .read_json import read_json diff --git a/src/check_datapackage/check.py b/src/check_datapackage/check.py index 51b63b7a..0af59457 100644 --- a/src/check_datapackage/check.py +++ b/src/check_datapackage/check.py @@ -8,7 +8,7 @@ from check_datapackage.config import Config from check_datapackage.constants import DATA_PACKAGE_SCHEMA_PATH, GROUP_ERRORS from check_datapackage.custom_check import apply_custom_checks -from check_datapackage.exclude import exclude +from check_datapackage.exclusion import exclude from check_datapackage.internals import ( _filter, _flat_map, diff --git a/src/check_datapackage/config.py b/src/check_datapackage/config.py index 7e496f5f..6182e496 100644 --- a/src/check_datapackage/config.py +++ b/src/check_datapackage/config.py @@ -2,7 +2,7 @@ from typing import Literal from check_datapackage.custom_check import CustomCheck -from check_datapackage.exclude import Exclusion +from check_datapackage.exclusion import Exclusion @dataclass diff --git a/src/check_datapackage/exclude.py b/src/check_datapackage/exclusion.py similarity index 100% rename from src/check_datapackage/exclude.py rename to src/check_datapackage/exclusion.py diff --git a/tests/test_check.py b/tests/test_check.py index ac2da2ab..05eb94ab 100644 --- a/tests/test_check.py +++ b/tests/test_check.py @@ -6,7 +6,7 @@ example_package_properties, example_resource_properties, ) -from check_datapackage.exclude import Exclusion +from check_datapackage.exclusion import Exclusion from tests.test_custom_check import lowercase_check # Without recommendations diff --git a/tests/test_exclude.py b/tests/test_exclusion.py similarity index 99% rename from tests/test_exclude.py rename to tests/test_exclusion.py index f8b8a011..d4863c67 100644 --- a/tests/test_exclude.py +++ b/tests/test_exclusion.py @@ -5,7 +5,7 @@ from check_datapackage.check import check from check_datapackage.config import Config from check_datapackage.examples import example_package_properties -from check_datapackage.exclude import Exclusion +from check_datapackage.exclusion import Exclusion def test_exclusion_none_type_and_jsonpath(): From 401a396d8105af21dedfedb13291790011257796 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Signe=20Kirk=20Br=C3=B8db=C3=A6k?= Date: Mon, 20 Oct 2025 16:24:56 +0200 Subject: [PATCH 3/4] test: :memo: add missing docstrings in `test_exclusion.py` --- tests/test_exclusion.py | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/tests/test_exclusion.py b/tests/test_exclusion.py index d4863c67..0e58e486 100644 --- a/tests/test_exclusion.py +++ b/tests/test_exclusion.py @@ -9,6 +9,7 @@ def test_exclusion_none_type_and_jsonpath(): + """Default Exclusion (without type and jsonpath) doesn't exclude default checks.""" properties: dict[str, Any] = { "name": "a name", "resources": [{"name": "a name", "path": "data.csv"}], @@ -102,6 +103,7 @@ def test_exclusions_multiple_types(): ], ) def test_exclusion_jsonpaths(jsonpath: str, num_issues: int) -> None: + """Exclusion by various jsonpaths.""" properties = example_package_properties() # Total 3 issues properties["created"] = "20240614" @@ -117,6 +119,7 @@ def test_exclusion_jsonpaths(jsonpath: str, num_issues: int) -> None: def test_exclusion_multiple_jsonpaths(): + """Exclusion by multiple jsonpaths.""" properties = example_package_properties() properties["created"] = "20240614" properties.update({"contributors": [{"path": "/a/bad/path"}]}) @@ -132,6 +135,7 @@ def test_exclusion_multiple_jsonpaths(): def test_exclusion_jsonpath_and_type(): + """Exclusion by jsonpath and type.""" properties = example_package_properties() properties["contributors"] = [{"path": "/a/bad/path"}, {"path": "/a/bad/path"}] @@ -145,6 +149,7 @@ def test_exclusion_jsonpath_and_type(): def test_exclusion_jsonpath_and_type_non_overlapping(): + """Exclusion by jsonpath and type where no overlap occurs.""" properties = example_package_properties() # There should be two issues properties["created"] = "20240614" From 8484086c9b2d6db2355e5f4c7f2205011a06d83a Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Signe=20Kirk=20Br=C3=B8db=C3=A6k?= Date: Mon, 20 Oct 2025 16:27:33 +0200 Subject: [PATCH 4/4] style: :art: format `qmd` --- docs/guide/config.qmd | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/docs/guide/config.qmd b/docs/guide/config.qmd index 644e4749..0a1ce384 100644 --- a/docs/guide/config.qmd +++ b/docs/guide/config.qmd @@ -57,8 +57,8 @@ exclusion_desc_required = cdp.Exclusion(type="required", jsonpath="$.resources[* This will exclude required checks on the `description` field of Data Resource descriptors. -To apply your exclusions when running the `check()`, you add them to -the `Config` object passed to the `check()` function: +To apply your exclusions when running the `check()`, you add them to the +`Config` object passed to the `check()` function: ```{python} package_descriptor = {