max
f90e1bc2cf
fix(unique): ignore comments when comparing array elements
...
The unique operator computed the dedup key for non-scalar elements by
encoding them to YAML, which includes their head/line/foot comments. A
comment sitting between two otherwise equal objects attaches to one of
them, changing its encoding, so the duplicates were wrongly kept. Encode
a comment-free copy of the node for the key so uniqueness depends on the
data only.
Fixes #2491
2026-06-28 04:16:46 +02:00
Mike Farah
3ea19ad2ed
clean code
2024-06-15 17:06:17 +10:00
Mike Farah
42120e1341
Unique now works on maps and arrays #2068
2024-06-15 17:04:48 +10:00
Mike Farah
3c3f1180d9
Cleaning up log message formats
2024-02-16 09:44:22 +11:00
Mike Farah
010750daf6
Updated to latest golint
2024-01-11 13:17:34 +11:00
Mike Farah
13d1bbb45f
Generic ast ( #1829 )
...
Remove dependency on yaml.Node for internal AST representation. Yaml decoder is now just another decoder.
2023-10-18 12:11:53 +11:00
Mike Farah
8d3be1a23c
Length (and some other operators) should not include head/foot comments #1231
2022-05-31 16:28:53 +10:00
Mike Farah
26356ff4be
Added github action fix for parsing xml, updated linter
2022-02-07 11:55:55 +11:00
Mike Farah
b44fecdfa5
Added key operator
2021-11-24 09:57:35 +11:00
Mike Farah
3f51a44596
Fixing readonly ops not to modify context when paths dont exist
2021-05-16 14:00:30 +10:00
Mike Farah
f4392f8658
Added any_c and all_c operators
2021-05-14 15:03:28 +10:00
Mike Farah
8627441705
Added unique operator
2021-05-14 09:43:52 +10:00