- Fixed
List
andSet
restricting mappings from their valid input. - Fixed cloning and representing of
Const
validator constructed withFalse
orNone
a value. - Fixed nullable check of
Type
validator constructed withobject
as a type.
- Dropped Python 3.5 support.
- Added Python 3.10, 3.11 support.
- Fixed handling UNIX-timestamps by
Date
andDatetime
validators. - Added ability to specify default time which is used to implicitly convert
date
todatetime
withinDatetime
validator. - Fixed handling
bool
values byInt
andFloat
validators. - Changed behavior of
Str
validator, it now strips leading & trailing whitespace by default. Usedontstrip=True
parameter to disable the stripping. - Added ability to normalize spaces by
Str
validator, i.e. replace space sequences by single space character. Usenormspace=True
parameter to enable the normalization. - Added
coerce
parameter toStr
validator, which can be useful to sanitize data from sources with automatic type inferring, where string data might be incorrectly interpreted as another type. - Unified behavior of Python and Cython versions of
Int
validator. Both versions support unlimited integer numbers now. - Added new
Set
validator. - Added new
Decimal
validator. - Renamed
FloatValueError
toNumberError
, so it is now used for bothFloat
andDecimal
validators. - Added new
CoerceError
which is raised instead ofInvalidTypeError
when type coercion fails.
- Dropped Python 2.7 support.
- Fixed
relmin/relmax
checks forDate
validator with timezone. - Fixed constructing Cython version of
Type
validator with type created from metaclass.
- Fixed type declarations for
Validator.clone()
method.
- Added Python 3.8 into test matrix.
- Made validators immutable.
- Added contracts checks on validator initialization.
- Added new simplified syntax for cloning validators.
- Got rid of global state within
LazyRef
validator. It now acts like a pure function. - Fixed raising of ambiguous
MinLengthError
onList
andDict
validation.
- Fixed type declarations. Again. One does not simply make mypy happy.
- Removed confusing nullable check from
Any
validator. - Fixed type declarations.
- Fixed library objects pickling.
- Fixed checking of length within
List
validator.
- Fixed handling of default values and length validation within
Dict
validator.
- Added support of timezones into
Date
andDatetime
validators. - Added support of custom parsers into
Date
,Time
, andDatetime
validators. - Added
Type
validator for custom types.
- Initial release.