honeybadger-io / honeybadger-ruby

Ruby gem for reporting errors to honeybadger.io
https://docs.honeybadger.io/lib/ruby/
MIT License
250 stars 146 forks source link

fix: don't raise errors in instrumentation metrics #627

Closed roelbondoc closed 5 days ago

roelbondoc commented 6 days ago

Raising an error just because a value isn't specified is a little too aggressive. Instead, we can still register the metric and just log the issue. This should prevent unwanted exceptions from bubbling up into the application. We should also not send any metrics if no samples have been collected.

Before submitting a pull request, please make sure the following is done:

  1. If you've fixed a bug or added code that should be tested, add tests!
  2. Run rake spec in the repository root.
  3. Use a pull request title that conforms to conventional commits.