| Total Complexity | 3 |
| Total Lines | 12 |
| Duplicated Lines | 0 % |
| 1 | import eradicate |
||
| 6 | class PyCommentedCodeBear(CorrectionBasedBear): |
||
| 7 | GET_REPLACEMENT = staticmethod( |
||
| 8 | lambda file: |
||
| 9 | (list(eradicate.filter_commented_out_code(''.join(file))), [])) |
||
| 10 | RESULT_MESSAGE = "This file contains commented out source code." |
||
| 11 | |||
| 12 | def run(self, filename, file): |
||
| 13 | """ |
||
| 14 | Detects commented out source code in Python. |
||
| 15 | """ |
||
| 16 | for result in self.retrieve_results(filename, file): |
||
| 17 | yield result |
||
| 18 |