Revision history for LIVR
2.3.1 2026-11-08T16:16:23+02:00
- "url" checks the host and the port as LIVR 2.5 specifies now: it rejects a dot after the
host, such as "https://www.google." or "http://example.com./path", host labels longer
than 63 characters, ports above 65535 or of more than 5 digits, and a ":" without a
port. Hosts without a dot, such as "localhost", and IPv4 addresses pass as before
- Updated the LIVR 2.5 test suite, with the new "url" cases
2.3.0 2026-11-07T23:48:56+02:00
- The rules of LIVR 2.5: boolean, any, required_if, not_one_of, digits,
starts_with, ends_with, contains, max_decimals, iso_datetime, iso_time, bounds for
iso_date ({ iso_date => { max => 'today' } }), split, when, values, keys, list_length,
unique, uuid, ip, cidr, hostname, base64, hex, digest, mongo_id, hex_color, mac, e164,
semver, jwt, luhn, credit_card and iban. They die on wrong arguments,
{ boolean => Any } (null) included
- The bounds "today", "yesterday" and "tomorrow" use the system clock in UTC. Tests fix it
by wrapping "time", see README
- The LIVR 2.0 rules ignore extra arguments instead of dying: { required => 1 },
{ max_length => [5, 1] }
- "iso_date" dies when its first argument is not an options object: { iso_date => 'today' }
checked nothing in LIVR 2.0. { iso_date => Any } (null) is the plain iso_date
- "eq" and "one_of" compare booleans as strings: { eq => True } accepts True and "true",
and still "True" as in LIVR 2.0
- { default => Any } builds: it sets an empty value to Any
- Aliases and "or" are transparent: their rules see the other fields of the object, so
"equal_to_field" works in them. In "list_of" the other field is missing
- Faster validator construction: nested validators of meta rules and aliases share the rules
of their validator instead of copying them, "or" builds one validator for all rule sets.
The format, checksum, list and date rules are loaded on first use
- Updated the LIVR 2.0 test suite, added the LIVR 2.5 test suite
2.2.1 2026-10-19T14:07:42+03:00
- README lists all supported rules with links to the specification
- README mentions that LIVR has no dependencies, fixed typos, updated the copyright years
2.2.0 2026-10-19T12:47:41+03:00
- Released to the Zef ecosystem, the auth is zef:koorchik now. Earlier versions are on CPAN
with the auth cpan:KOORCHIK.
- Module files have the .rakumod extension instead of .pm6
- Compiles on current Rakudo: the "url" rule does not use a Perl 5 regex (:P5) anymore,
which the RakuAST compiler (the default one in Rakudo 2026.09) does not support
- "like" accepts regex strings in the common syntax (JavaScript, Perl, PCRE), as the
specification requires, besides Raku regexes
- "email" checks addresses like the JavaScript implementation, without Email::Valid.
Addresses with line breaks are rejected.
- LIVR has no dependencies now. JSON::Tiny is needed for the tests only.
- "or" passes empty values to its rule sets too, so "required" and "not_empty" in them work
- "list_of_different_objects" and "variable_object" return FORMAT_ERROR when the selector
value is a list or a hash
- "equal_to_field" does not warn when the other field is missing
- Updated the test suite to the current LIVR test suite
- Tests run on GitHub Actions with Rakudo 2024.02 and the newest one, instead of Travis CI
- Faster: building a validator with string "like" regexes is up to 21 times faster, as the
regexes are compiled once, validation is 1.4-2.3 times faster, the LIVR test suite runs
5.7 times faster