mirror of
https://github.com/PyCQA/flake8.git
synced 2026-04-05 12:36:54 +00:00
@BackSeat contributed the patch. Signature changes are mentioned in README.
This commit is contained in:
parent
cc1d7c5385
commit
82ea7edadc
4 changed files with 14 additions and 9 deletions
|
|
@ -3,8 +3,10 @@ import re
|
|||
import os
|
||||
|
||||
|
||||
def skip_warning(warning):
|
||||
def skip_warning(warning, ignore=[]):
|
||||
# XXX quick dirty hack, just need to keep the line in the warning
|
||||
if warning.message.split()[0] in ignore:
|
||||
return True
|
||||
if not os.path.isfile(warning.filename):
|
||||
return False
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue