Failed Conditions
Pull Request — master (#1127)
by Mischa
01:56
created

coalib.results.result_actions.Result.to_ignore()   B

Complexity

Conditions 6

Size

Total Lines 17

Duplication

Lines 0
Ratio 0 %
Metric Value
cc 6
dl 0
loc 17
rs 8
1
from coalib.results.result_actions.ResultAction import ResultAction
2
from coalib.results.Result import Result
3
4
5
class PrintDebugMessageAction(ResultAction):
6
    @staticmethod
7
    def is_applicable(result, original_file_dict, file_diff_dict):
8
        return isinstance(result, Result) and result.debug_msg != ""
9
10
    def apply(self, result, original_file_dict, file_diff_dict):
0 ignored issues
show
Duplication introduced by
This code seems to be duplicated in your project.

Duplicated code is one of the most pungent code smells. If you need to duplicate the same code in three or more different places, we strongly encourage you to look into extracting the code into a single class or operation.

You can also find more detailed suggestions in the “Code” section of your repository.

Loading history...
11
        """
12
        Print the debug message of the result.
13
        """
14
        print(result.debug_msg)
15
16
        return file_diff_dict
17