[BUG] salt.states.grains.list_present append already existing values #61869
Labels
Bug
broken, incorrect, or confusing behavior
severity-high
2nd top severity, seen by most users, causes major problems
Milestone
Description
According the documentation, salt.states.grains.list_present should only add a value to a a grain formatted as a list if it doesn't exist.
It's possible to pass multiple grains, but then, if one of them isn't present, the full list is added, including already existing items.
Steps to Reproduce the behavior
A minimal repro case from the salt.states doc and an update:
Expected behavior
grain serve_roles should contain web, dev, mail, only once for web and dev
Versions Report
salt 3004.1, repro with salt-call --local
The text was updated successfully, but these errors were encountered: