lib/sentry/rails/railtie.rb in sentry-rails-5.3.1 vs lib/sentry/rails/railtie.rb in sentry-rails-5.4.0

- old
+ new

@@ -51,9 +51,14 @@ end runner do next unless Sentry.initialized? Sentry.configuration.background_worker_threads = 0 + + at_exit do + # TODO: Add a condition for Rails 7.1 to avoid confliction with https://github.com/rails/rails/pull/44999 + Sentry::Rails.capture_exception($ERROR_INFO, tags: { source: "runner" }) if $ERROR_INFO + end end def configure_project_root Sentry.configuration.project_root = ::Rails.root.to_s end