def filter_skiplines(code, errors):
 if (not errors):
  return errors
 enums = set((er.lnum for er in errors))
 removed = set([num for (num, l) in enumerate(code.split('\n'), 1) if ((num in enums) and SKIP_PATTERN(l))])
 if removed:
  errors = [er for er in errors if (er.lnum not in removed)]
 return errors

def filter_skiplines ( code , errors ) : if ( not errors ) : return errors enums = set ( ( er . lnum for er in errors ) ) removed = set ( [ num for ( num , l ) in enumerate ( code . split ( '\n' ) , 1 ) if ( ( num in enums ) and SKIP_PATTERN ( l ) ) ] ) if removed : errors = [ er for er in errors if ( er . lnum not in removed ) ] return errors
filter lines by noqa .