We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 3406714 commit 9455b14Copy full SHA for 9455b14
src/attributecode/cmd.py
@@ -24,6 +24,7 @@
24
25
import click
26
import unicodecsv
27
+import sys
28
29
import attributecode
30
from attributecode import CRITICAL
@@ -225,10 +226,16 @@ def check(location):
225
226
errors, abouts = attributecode.model.collect_inventory(location)
227
228
msg_format = '%(sever)s: %(message)s'
229
+ print_errors = []
230
for severity, message in errors:
231
sever = severities[severity]
232
if sever in important_errors:
- print(msg_format % locals())
233
+ print_errors.append((msg_format % locals()))
234
+
235
+ if print_errors:
236
+ for err in print_errors:
237
+ print(err)
238
+ sys.exit(1)
239
240
241
def log_errors(errors, quiet, base_dir=False):
0 commit comments