-
Notifications
You must be signed in to change notification settings - Fork 5.5k
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
[BUG] module.run new style defintion is identified as legacy #62988
Comments
What happens if you use
|
Thanks for looking at this @OrangeDog . The states are a part of cmplex setup which I cannot tinker too much. I will try to setup a simpler environment on a test machine to reproduce this and add more information |
@OrangeDog I have reproduced this in a simpler setup There is a custom module
I have added a logging line after this line on minion to log the keys
Case 1 - require and module.run - Pass
Case 2 - module.wait and watch - FAIL
Case 3 - watch_in and module.wait - FAIL
Case 4 - onchanges_in and module.run
It looks like In our setup, we cannot easily switch to the |
I think I don't know how long it's going to take for someone to get around to fixing this. |
I can take a stab at generating a PR for this if the change is to simply ignore |
Description
New style
module.run
is considered legacy Salt version - 3005 leading to failuresSetup
Consider a state file that has the following state to invoke a custom module
something.do
And this state is referenced in another stae file
Trying to run the state causes an error
Module function some foo
is not availableSteps to Reproduce the behavior
The debug logs are
Expected behavior
The state should be detected as using new style
module.run
and should run as expectedScreenshots
If applicable, add screenshots to help explain your problem.
Versions Report
salt --versions-report
(Provided by running salt --versions-report. Please also mention any differences in master/minion versions.)Additional context
Tinkering with the source in
states/modules.py
to add logging for offending keys that are triggering detection as legacy style gives following logswhich shows that additional
kwargs
sfun
and__reqs__
which are not handled in code maybe triggering the legacy flag. The code ignores thename
kwarg but does not handle the other two addtional kwargs.The text was updated successfully, but these errors were encountered: