Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Error 'undefined method `each' for nil:NilClass' thrown if 'pillars' is not defined #343

Open
4x0v7 opened this issue Apr 8, 2022 · 0 comments

Comments

@4x0v7
Copy link

4x0v7 commented Apr 8, 2022

If pillars are not defined, an error is thrown:

Message: Failed to complete #converge action: [undefined method `each' for nil:NilClass]

Looking at the code, it's coming from this line:
https://github.com/saltstack/kitchen-salt/blob/v0.7.2/lib/kitchen-salt/pillars.rb#L63

If a user is defining pillars_from_directories or pillars_from_files I think that should be taken into account by the prepare_pillar_files function, am I reading the code correctly?

My workaround is to just define pillars to be the same as what I'd like to import using pillars_from_directories

I'm still understanding the codebase while working on developing some salt states, so I might not be fully understanding something here..

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant