mirror of
https://github.com/max-sixty/worktrunk.git
synced 2026-11-26 13:37:01 +08:00
A `wt list` custom column that converts a `vars.*` or `git.branch.*`
value to a number — e.g. `{% if (git.branch.ahead | default(0) | int) >
0 %}` — failed config validation with `invalid float literal`, which
aborts `wt list` (the picker drops custom columns with a warning). The
template renders fine against real values; the failure came only from
the validation trial render, which answered every `vars.*` /
`git.branch.*` key with the string `"PLACEHOLDER"`.
The placeholder is now `"1"`: runtime values are strings and often
numeric (counts, ports), so `| int` / `| float` succeed, and string
filters accept it as before. Misspelled filters and syntax errors are
still rejected. The row-identity variables (`branch`, `worktree_path`,
`worktree_name`) keep their old placeholder.
Found via the stacked-branch columns shared in #1983, whose README lists
"filters like `| int` break all of `wt list`" as a limitation. The
extended `test_validate_list_column_template` fails without the change;
reproduced and verified end-to-end with a `--config-set` column against
a branch whose `branch.<name>.baseahead` is set.
Refs #1983
Co-authored-by: worktrunk-bot <254187624+worktrunk-bot@users.noreply.github.com>