Paramtools

Latest version: v0.18.1

Safety actively analyzes 626604 Python packages for vulnerabilities to keep your Python projects secure.

Scan your dependencies

Page 3 of 6

0.13.1

- Make integer validation strict so that floats are now invalid. (98)
- Fixes bug where errors were not raised when passing a list value to a non-list parameter. (99)
- Fix error messages for labels. (100)

0.13.0

- Add `delete` method for removing a parameter's value objects. (95)
- Round out select module with the `select_lte` and `select_gte` functions. (96)
- Makes `exact_match` keyword on `Parameters.select_*` methods optional. (96)
- Fixes bug where `select_lt` was left out of top-level import. (96)

0.12.0

- Streamline steps to add custom types with a new [`register_custom_type`](https://paramtools.dev/api/custom-types/) function. This makes it easy to register a custom type that can be used through out the `defaults` config file. (#93)
- Add ability to select value objects based on whether a label is less than or equal to some value with the new `select_lt` function. (90)
- Update the docs website with a slick new theme from [Material for MkDocs](https://squidfunk.github.io/mkdocs-material/), add the beginnings of an API reference page using [`mkautodoc`](https://github.com/tomchristie/mkautodoc), and move the docs website to https://paramtools.dev (#94)
- Removes warnings that are shown when adjusting a value for a parameter that is not active in the current state of the `Parameters` instance. (91)

0.11.1

- Bug fix for custom fields. This feature was accidentally removed in 72. (89)

0.11.0

- Add a warnings distinction to validators. By default, validators throw errors, but you may specify that they emit warnings instead (86):
json
"range": {"min": 0, "max": 10, "level": "warn"}


- Adds a new `when` validator, that allows you to specify complex conditional validation logic. Here's an example using [Tax-Cruncher's](https://github.com/PSLmodels/Tax-Cruncher) social security parameter (#81):

json
{
"when": {
"param": "spouse_age",
"is": {"less_than": 65},
"then": {
"when": {
"param": "primary_age",
"is": {"less_than": 65},
"then": { "range": {"min": 0, "max": 0} },
"otherwise": { "range": {"min": 0, "max": 9e99} }
}
},
"otherwise": { "range": {"min": 0, "max": 9e99} }
}
}

- A bug fix for the `sort_values` method and its usage in `dump`. (87)

0.10.3

- Add a `sort_values` method for to re-order value objects that may get shuffled after operations like `extend` or `adjust`. The `dump` method now ensures that the results are sorted by default. (84, 85)

Page 3 of 6

© 2024 Safety CLI Cybersecurity Inc. All Rights Reserved.