code: def find_diff_violations(self, patch):
          
          violations = collections.defaultdict(list)
          for line in patch.changed_lines:
              file_violations = self._all_violations.get(line['file_name'])
              if not file_violations:
                  continue
  
              line_violations = [v for v in file_violations if v.line == line['line_number']]
  
              for v in line_violations:
                  violations[line['file_name']].append(v)
  
          return violations
docs: Uses the diff for this build to find changed lines that also have violations.