bugsnag/bugsnag-ruby

Bugsnag still reporting although release stage is not included

letiesperon opened this issue · 0 comments

Describe the bug

I am working on localhost and I don't want my errors to be reported. However, I can see them on Bugsnag. I can see the API call being made in the browser although in the console I see the message:

Not notifying due to notify_release_stages :["production", "staging"]

I've printed out Bugsnag.configuration.release_stage on the logs and it says development, so the issue is not that it's not configured.

Steps to reproduce

  1. On local, add bugsnag (6.20.0) to gemfile
  2. Add the following configuration in intializer:
# frozen_string_literal: true

require "bugsnag/meta_data_middleware"

Bugsnag.configure do |config|
  ignore_classes = [
    AbstractController::ActionNotFound,
    ActionController::InvalidAuthenticityToken,
    ActionController::ParameterMissing,
    ActionController::RoutingError,
    ActionController::UnknownFormat,
    ActionController::UnknownHttpMethod,
    ActiveRecord::RecordNotFound,
    SignalException,
    SystemExit,
    Sidekiq::Limiter::OverLimit
  ]

  config.api_key = ENV["BUGSNAG_API_KEY"]
  config.notify_release_stages = %w[production staging]
  config.ignore_classes = Set.new(ignore_classes)

  config.middleware.use Bugsnag::MetaDataMiddleware
end
  1. Add a valid API KEY
  2. Go to the browser, open inspect mode and trigger and exception. You can see the bugsnag call being made and the error shown in the Bugsnag dashboard.

Environment

  • Bugsnag version: 6.20.0
  • Ruby version: 2.6.6p146 (2020-03-31 revision 67876) [x86_64-darwin19]
  • Bundle version: 2.1.4
  • Integration framework version:
    • Rack: 2.2.3
    • Rails: 6.0.3.7
    • Rake: 13.0.3
    • Sidekiq: 5.2.9

Thank you!