Search code examples
ruby-on-railssentryraven

how to find sentry issue by event id or custom Raven.user_context?


In my system, when users see program error (status is 500), they can write details in feedback form and submit it.

# for sentry
Raven.user_context sentry_uid: SecureRandom.uuid

and

-# feedback form
- form_for @feedback do |form|
  = input :sentry_uid

Question is: How to find sentry issue by sentry_uid?


Solution

  • We dont support searching by arbitrary values, but what you can do is:

    • Use tags_context to bind 'sentry_uid'
    • Use user_context.id (or similar) to bind a real user ID

    Once either of those are done, you can use either 'sentry_uid:foo' or 'user.id:foo' in the search query.