Kida 0.2.7
Fail-fast filter errors, typeof, nested slot passthrough fixes, and clearer runtime suggestions
Status: Released March 12, 2026.
Kida 0.2.7 focuses on safer filter behavior, clearer runtime guidance, and a fix for nested slot passthrough in component-style templates.
Highlights
- Fail-fast filter behavior —
joinandreversenow require iterable input instead of silently stringifying scalars. - Numeric coercion improvements —
replacecoerces string counts from YAML/config, anddecimal/format_numbersupportstrict=truefor explicit failures. typeoffilter — Inspect incoming template values with normalized names likebool,int,float,path,list,dict,none, andstr.- Macro collision diagnostics — Better runtime messages when imported macros shadow context variables and are accidentally used as iterables.
- Nested slot passthrough fix — Empty or whitespace-only inner slots now delegate correctly to the outer caller.
Added
Type Inspection
typeoffilter — New debugging filter for mixed template/config data.
Diagnostics
- Macro iteration error guidance — Imported macros now raise a targeted error with a naming
recommendation such as
render_route_tabswhen a macro shadows a context variable.
Changed
joinandreversefilters (breaking) — Non-iterable input now raisesTypeErrorinstead of falling back to stringification.pluralize— Non-numeric input now raises with a suggestion to coerce using| int.replace—countnow accepts YAML/config strings that can be coerced to integers and raises on invalid values.decimalandformat_number— Both filters addstrict=truefor explicit conversion failures.- Runtime suggestions — Error enhancement now recognizes macro iteration collisions,
%vs{}format mistakes, invalid numeric literals,strftimeformatting issues, and sequence-only filters.
Fixed
- Nested slot passthrough — In nested
{% def %}/{% call %}/{% slot %}chains, empty or whitespace-only inner slot bodies now delegate to the outer caller instead of swallowing the outer slot content.
Upgrade Notes
- Check templates using
joinorreverseon scalars — Convert values to iterables first. - Prefer explicit numeric coercion for config-driven values —
| intand| floatmake intent clearer. - Avoid macro/context name collisions — Use verb-prefixed macro names and noun-like context variable names.