From c2db0835294f8ac16d81498d2a05e9c20d82de74 Mon Sep 17 00:00:00 2001 From: Sebastian Serth Date: Tue, 27 Oct 2020 01:11:31 +0100 Subject: [PATCH] Hotfix: LinterCheckRun rescue within each loop --- app/models/linter_check_run.rb | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/app/models/linter_check_run.rb b/app/models/linter_check_run.rb index 851130e8..c53ce92c 100644 --- a/app/models/linter_check_run.rb +++ b/app/models/linter_check_run.rb @@ -22,9 +22,9 @@ class LinterCheckRun < ApplicationRecord testrun: testrun, file: file ) + rescue ActiveRecord::RecordInvalid + # Something bad happened. Probably, the RegEx in lib/py_lint_adapter.rb didn't work. + Raven.extra_context(testrun: testrun, linter_result: linter_result) end - rescue ActiveRecord::RecordInvalid - # Something bad happened. Probably, the RegEx in lib/py_lint_adapter.rb didn't work. - Raven.extra_context(testrun: testrun, linter_result: linter_result) end end