sentry-python icon indicating copy to clipboard operation
sentry-python copied to clipboard

Add file name and line number to logentry

Open armenzg opened this issue 1 year ago • 0 comments

Problem Statement

I want more metadata in logentry so I can create GitHub/GitLab links from the Issue Details page.

Solution Brainstorm

logentry [1] does not have enough metadata to create a link back to GitHub. If you add the file name and line number it would be sufficient for me.

For instance, this issue shows this under Message: image

If I had the extra metadata, I could create a hyperlink to this line (which is where the error is raised): https://github.com/getsentry/sentry/blob/817cc75c6f22bdfcd05bc08cafdb6e89046e1e41/src/sentry/utils/safe.py#L43

[1]

"logentry": {
    "message": "%s.process_error",
    "formatted": "send_notification.process_error",
    "params": [
      "send_notification"
    ]
  },

armenzg avatar Feb 29 '24 17:02 armenzg