Fixes #41
Seems like the patch that fixed skipping some warnings broke this.
diff --git a/flake8/util.py b/flake8/util.py
index 1cd61b0..8f1877d 100644
--- a/flake8/util.py
+++ b/flake8/util.py
@@ -5,6 +5,9 @@
def skip_warning(warning, ignore=[]):
# XXX quick dirty hack, just need to keep the line in the warning
+ if not hasattr(warning, message):
+ # McCabe's warnings cannot be skipped afaik, and they're all strings.
+ return False
if warning.message.split()[0] in ignore:
return True
if not os.path.isfile(warning.filename):