Skip to content

Commit

Permalink
update to _hook for new marshmallow
Browse files Browse the repository at this point in the history
  • Loading branch information
jdebacker committed Aug 27, 2024
1 parent b4a1329 commit 5518b07
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion paramtools/schema.py
Original file line number Diff line number Diff line change
Expand Up @@ -204,7 +204,7 @@ def validate_only(self, data):
error_store=error_store, data=data, many=None
)
# Run schema-level validation
if self._has_processors(decorators.VALIDATES_SCHEMA):
if self._hooks[decorators.VALIDATES_SCHEMA]:
field_errors = bool(error_store.errors)
self._invoke_schema_validators(
error_store=error_store,
Expand Down
2 changes: 1 addition & 1 deletion paramtools/tests/test_parameters.py
Original file line number Diff line number Diff line change
Expand Up @@ -1017,7 +1017,7 @@ def test_range_validation_on_list_param(self, TestParams):
]
}
params.adjust(adj, raise_errors=False)
exp = ["float_list_param[label0=zero, label1=1] [np.float64(-1.0), np.float64(1.0)] < min 0 "]
exp = ["float_list_param[label0=zero, label1=1] [-1.0, 1.0] < min 0 "]

assert params.errors["float_list_param"] == exp

Expand Down

0 comments on commit 5518b07

Please sign in to comment.