1
0
Fork 0
mirror of https://github.com/ansible-collections/community.general.git synced 2026-05-13 05:02:17 +00:00
community.general/plugins/filter
Max Gautier a789bd128f
Add the accumulate filter (#9133)
* Add the accumulate filter

- Add myself as a maintainer for it.
- Some integration tests.

* accumulate: fix documentation and add test aliases

The aliases file was copied over from
tests/integrations/targets/filter_dict/aliases as the documentation[1]
suggests to use the same group as existing similar tests.

[1]: https://docs.ansible.com/ansible/latest/dev_guide/testing/sanity/integration-aliases.html

Suggested-by: Felix Fontein <felix@fontein.de>

* accumulate: documentation: markup consistency with other plugins

Suggested-by: Felix Fontein <felix@fontein.de>
Suggested-by: Alexei Znamensky <103110+russoz@users.noreply.github.com>

* filter/accumulate: Validate input is a Sequence

Accepting arbitrary iterables might lead to surprising behavior so we
are stricter on what we accept in the filter.
Relaxing those requirements is easier than retrofitting them, in terms
of backwards compatibility.

Suggested-by: Felix Fontein <felix@fontein.de>
Signed-off-by: Max Gautier <mg@max.gautier.name>

* filter/accumulate: Document the behavior with a string

Signed-off-by: Max Gautier <mg@max.gautier.name>

---------

Signed-off-by: Max Gautier <mg@max.gautier.name>
2024-12-02 20:20:13 +01:00
..
accumulate.py Add the accumulate filter (#9133) 2024-12-02 20:20:13 +01:00
counter.py
crc32.py feat: Add crc32 filter (#5062) 2022-08-21 12:10:31 +02:00
dict.py filters/dict: document the correct return value (#9145) 2024-11-18 20:42:14 +01:00
dict_kv.py
from_csv.py Update from_csv.py docs (#7296) 2023-09-20 22:02:54 +02:00
from_ini.py fix: Ensuring interpolation is disabled for ConfigParser (#8185) 2024-04-09 08:01:44 +02:00
groupby_as_dict.py groupby_as_dict: mention Jinja2's groupby filter (#9040) 2024-10-19 22:07:56 +02:00
hashids.py Use dict comprehension in plugins (#8814) 2024-09-01 20:22:53 +02:00
hashids_decode.yml Add default license header to files which have no copyright or license header yet (#5074) 2022-08-05 14:03:38 +02:00
hashids_encode.yml Add default license header to files which have no copyright or license header yet (#5074) 2022-08-05 14:03:38 +02:00
jc.py Start using semantic markup (#6627) 2023-06-10 09:28:40 +02:00
json_query.py Add more license statements (#5079) 2022-08-07 13:37:23 +02:00
keep_keys.py Use dict comprehension in plugins (#8814) 2024-09-01 20:22:53 +02:00
lists.py New filters to calculate the union, intersection, difference and symmetric difference of lists by preserving the items order (#7985) 2024-02-23 20:35:09 +01:00
lists_difference.yml New filters to calculate the union, intersection, difference and symmetric difference of lists by preserving the items order (#7985) 2024-02-23 20:35:09 +01:00
lists_intersect.yml New filters to calculate the union, intersection, difference and symmetric difference of lists by preserving the items order (#7985) 2024-02-23 20:35:09 +01:00
lists_mergeby.py Update docs lists_mergeby (#8475) 2024-06-13 07:35:32 +02:00
lists_symmetric_difference.yml New filters to calculate the union, intersection, difference and symmetric difference of lists by preserving the items order (#7985) 2024-02-23 20:35:09 +01:00
lists_union.yml New filters to calculate the union, intersection, difference and symmetric difference of lists by preserving the items order (#7985) 2024-02-23 20:35:09 +01:00
random_mac.py Add more license statements (#5079) 2022-08-07 13:37:23 +02:00
remove_keys.py Use dict comprehension in plugins (#8814) 2024-09-01 20:22:53 +02:00
replace_keys.py Use dict comprehension in plugins (#8814) 2024-09-01 20:22:53 +02:00
reveal_ansible_type.py New Plugins #8594 (#8595) 2024-07-13 13:32:36 +02:00
time.py
to_days.yml Start using semantic markup (#6627) 2023-06-10 09:28:40 +02:00
to_hours.yml Start using semantic markup (#6627) 2023-06-10 09:28:40 +02:00
to_ini.py fix: Ensuring interpolation is disabled for ConfigParser (#8185) 2024-04-09 08:01:44 +02:00
to_milliseconds.yml Start using semantic markup (#6627) 2023-06-10 09:28:40 +02:00
to_minutes.yml Start using semantic markup (#6627) 2023-06-10 09:28:40 +02:00
to_months.yml Start using semantic markup (#6627) 2023-06-10 09:28:40 +02:00
to_seconds.yml Start using semantic markup (#6627) 2023-06-10 09:28:40 +02:00
to_time_unit.yml Start using semantic markup (#6627) 2023-06-10 09:28:40 +02:00
to_weeks.yml Start using semantic markup (#6627) 2023-06-10 09:28:40 +02:00
to_years.yml Start using semantic markup (#6627) 2023-06-10 09:28:40 +02:00
unicode_normalize.py
version_sort.py