def get_violations_reports(violations_type):
 violations_files = []
 for (subdir, _dirs, files) in os.walk(os.path.join(Env.REPORT_DIR)):
  for f in files:
   if (f == '{violations_type}.report'.format(violations_type=violations_type)):
    violations_files.append(os.path.join(subdir, f))
 return violations_files

def get_violations_reports ( violations_type ) : violations_files = [ ] for ( subdir , _dirs , files ) in os . walk ( os . path . join ( Env . REPORT_DIR ) ) : for f in files : if ( f == '{violations_type}.report' . format ( violations_type = violations_type ) ) : violations_files . append ( os . path . join ( subdir , f ) ) return violations_files
finds violations reports files by naming convention .