Describe the bug
|
Sentry.configuration.rails.skippable_job_adapters << "ActiveJob::QueueAdapters::ResqueAdapter" |
This line in sentry-resque results in undefined method `rails' for #<Sentry::Configuration:* in rails applications that do not use sentry-rails.
To Reproduce
require 'bundler/inline'
gemfile do
source 'https://rubygems.org' do
gem 'rails'
gem 'sentry-resque'
# gem 'sentry-rails'
end
end
require "resque"
require "sentry-resque"
require "rails"
require "action_dispatch"
class TestApp < Rails::Application
Sentry.init do |config|
config.breadcrumbs_logger = [:sentry_logger]
config.dsn = 'https://aaaa@xxxx.ingest.sentry.io/123456'
end
end
TestApp.initialize!
Expected behavior
It should not result in NoMethodError.
Actual behavior
undefined method `rails' for #<Sentry::Configuration:0x00007f9397b2ae08> (NoMethodError)
Describe the bug
sentry-ruby/sentry-resque/lib/sentry-resque.rb
Line 19 in a50bf1f
This line in
sentry-resqueresults inundefined method `rails' for #<Sentry::Configuration:*in rails applications that do not usesentry-rails.To Reproduce
Expected behavior
It should not result in
NoMethodError.Actual behavior