old_contents: import eradicate
  
  from coalib.bearlib.abstractions.Lint import Lint
  from coalib.bears.LocalBear import LocalBear
  
  
  class PyCommentedCodeBear(Lint, LocalBear):
      gives_corrected = True
      diff_message = "This file contains commented out source code."
      LANGUAGES = ("Python", "Python 2", "Python 3")
  
      def lint(self, filename, file):
          output = list(eradicate.filter_commented_out_code(''.join(file)))
          return self.process_output(output, filename, file)
  
      def run(self, filename, file):
          """
          Detects commented out source code in Python.
          """
          return self.lint(filename, file)
  
new_contents: import eradicate
  
  from coalib.bears.LocalBear import LocalBear
  from coalib.results.Diff import Diff
  from coalib.results.Result import Result
  
  
  class PyCommentedCodeBear(LocalBear):
      LANGUAGES = ("Python", "Python 2", "Python 3")
  
      def run(self, filename, file):
          """
          Detects commented out source code in Python.
          """
          corrected = tuple(eradicate.filter_commented_out_code(''.join(file)))
  
          for diff in Diff.from_string_arrays(file, corrected).split_diff():
              yield Result(self,
                           "This file contains commented out source code.",
                           affected_code=(diff.range(filename),),
                           diffs={filename: diff})
  
subject: Remove Lint dependency