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

ShellScriptHandler plugin does not conform to base class interface #7

Open
srikanth-viswanathan opened this issue Oct 11, 2015 · 1 comment

Comments

@srikanth-viswanathan
Copy link

The declaration of execute_command in BaseHandler is:

        def execute_command(self):

However, the ShellScriptHandler overrides it as:

    def execute_command(self, script, arguments):

atropos.py also assumes this interface:

        handler_class = getattr(handler_module, handler_name)
        handler = handler_class(self.config_dir, target,
                                self.logger_instance, verbose=True)
        handler.authenticate()
        command_status, command_output, command_error = \
            handler.execute_command(coordinate, arguments)

I think atropos.py is meant to use the base class interface to remove the assumption that every handler has a "coordinate". Let me know if you accept patches and I'll work on this.

@MayureshGharat
Copy link
Contributor

This LGTM. You can sure submit a PR and we can go from there.

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

2 participants