Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > comp.lang.python.announce > #4321

[Python-announce] ANN: func-validator 1.1.1 release

From Patrick Boateng <patrickboateng@patrickboateng.tech>
Newsgroups comp.lang.python.announce
Subject [Python-announce] ANN: func-validator 1.1.1 release
Date 2025-10-17 17:15 -0500
Message-ID <05e4a9cf-8d59-4295-832f-0d8449090559@patrickboateng.tech> (permalink)

Show all headers | View raw


Hi All,

I am happy to announce **func-validator 1.1.1** , which provides 
argument validation for
python functions and methods. The main objective is to remove argument 
validation from
the function's body which reduces lines of code and improves code 
readability.

This package was inspired by MATLAB’s argument validation framework, 
bringing a similar level
of clarity and structure to Python function definitions.

Below is a quick example:

```python
from typing import Annotated
from func_validator import validate_params, MustBePositive, MustBeNegative

@validate_params
def func(a: Annotated[int, MustBePositive()], b: Annotated[float, 
MustBeNegative()]):
    ...
```

**Links**

  * PYPI: https://pypi.org/project/func-validator/
  * GitHub: https://github.com/patrickboateng/func-validator
  * Docs: https://func-validator.readthedocs.io/en/latest/


**Install**
pip install func-validator

Compatible with Python 3.11 - 3.13. Licensed under MIT

Best,
Patrick Boateng
patrickboateng@patrickboateng.tech


Back to comp.lang.python.announce | Previous | Next | Find similar


Thread

[Python-announce] ANN: func-validator 1.1.1 release Patrick Boateng <patrickboateng@patrickboateng.tech> - 2025-10-17 17:15 -0500

csiph-web