Posted 11 months ago. Visible to the public.

Sending errors to sentry from development

For the initial setup or changes in the sentry reporting it might be useful to enabled reporting of sentry in development. Don't commit these changes and prefer to report to the staging environment. As other developers might be confused of these errors try to given them a proper message and delete them afterwards.

  1. Add config.raven_dsn = 'your-dns' in config/environments/development.rb.
  2. Add development to existing environments in the Raven.configure block: config.environments = ['development', 'staging', 'production'].
  3. Remove better_errors from Gemfile if existing and bundle.

With Raven.capture_message('Test from development') you can test your setting on console. Raising an exception will now report to sentry. You can see this in the log:

INFO -- sentry: ** [Raven] Sending event c49343eec8argefb8bcasd193103244a to Sentry

Once an application no longer requires constant development, it needs periodic maintenance for stable and secure operation. makandra offers monthly maintenance contracts that let you focus on your business while we make sure the lights stay on.

Author of this card:

Emanuel De
Last edit:
11 months ago
by Emanuel De
About this deck:
We are makandra and do test-driven, agile Ruby on Rails software development.
License for source code
Posted by Emanuel De to makandra dev